unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* The problem of writing php code with emacs, Help!!
@ 2009-10-29  5:11 Cheney Chen
  2010-03-28  0:27 ` m.pontus
  2010-03-28  0:29 ` m.pontus
  0 siblings, 2 replies; 4+ messages in thread
From: Cheney Chen @ 2009-10-29  5:11 UTC (permalink / raw)
  To: help-gnu-emacs

I want to use emacs to write php code..first I tried php-mode with mmm-
mode, but I found a problem soon, when I press c-j quickly, there will
be a
"Wrong type argument: stringp, nil "
then the indentation does work....I don't know how to solve it...

Recently I am using nxhtml+emacsw32, but I still find a very confusing
problem..
when I type <?php
The first line has a very well indentation, just like
<?php
    echo "test";
But when the second line is completed, when I press ";", the whole
line will move to the left most, it looks like
<?php
    echo "test";
echo "test2";
#
The cursor will move to the location of "#' above...
I am very troubled by this problem..

if someone knows how to solve it, please help me.....


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: The problem of writing php code with emacs, Help!!
  2009-10-29  5:11 The problem of writing php code with emacs, Help!! Cheney Chen
@ 2010-03-28  0:27 ` m.pontus
  2010-03-29 20:28   ` Lennart Borgman
  2010-03-28  0:29 ` m.pontus
  1 sibling, 1 reply; 4+ messages in thread
From: m.pontus @ 2010-03-28  0:27 UTC (permalink / raw)
  To: help-gnu-emacs

Having the same problem. It may be better idea to put a bug into mmm-mode bug tracker, but if anyone is familiar with this problem, the solution would me much appreciated. 

I managed to get backtrace on error occurrence, here is what it says:
 Debugger entered--Lisp error: (wrong-type-argument stringp nil)
  c-syntactic-skip-backward(nil nil t)
  c-looking-at-decl-block(nil t)
  c-guess-basic-syntax()
  c-indent-line()
  c-electric-semi&comma(nil)
  call-interactively(c-electric-semi&comma nil nil)

My lack of elisp knowledge doesn't let me to help in fixing this issue.
I looked deeply for solution to this problem, unfortunately I didn't find anything but the advices of using mumamo instead. Well, I hesitate to accept this solution. nXhtml is a great package with a lot of features, but what i'm looking for is a simple multimode in a buffer which will let me jump between php, javascript and css in html document for indention and highlighting. Omitting the fact that nXhtml had insufficient performance without byte-compiling (i didn't try compiling it tbh) I don't like the idea of having one package for all tasks. Sorry if i misunderstood the role of nXhtml and mumamo package. 

P.S.
I can not vouch for the reliability of next words, but as far as i can remember, when i first installed and configured the package, i tried to write a file combined of html, php, css and javascript and it worked well including highlighting and indention. I can not remember if I changed something since that time, but now I'm having this annoying error just like the topic starter.

--
This message was sent on behalf of m.pontus@gmail.com at openSubscriber.com
http://www.opensubscriber.com/message/help-gnu-emacs@gnu.org/12975889.html




^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: The problem of writing php code with emacs, Help!!
  2009-10-29  5:11 The problem of writing php code with emacs, Help!! Cheney Chen
  2010-03-28  0:27 ` m.pontus
@ 2010-03-28  0:29 ` m.pontus
  1 sibling, 0 replies; 4+ messages in thread
From: m.pontus @ 2010-03-28  0:29 UTC (permalink / raw)
  To: help-gnu-emacs

Having the same problem. It may be better idea to put a bug into mmm-mode bug tracker, but if anyone is familiar with this problem, the solution would me much appreciated. 

I managed to get backtrace on error occurrence, here is what it says:
 Debugger entered--Lisp error: (wrong-type-argument stringp nil)
  c-syntactic-skip-backward(nil nil t)
  c-looking-at-decl-block(nil t)
  c-guess-basic-syntax()
  c-indent-line()
  c-electric-semi&comma(nil)
  call-interactively(c-electric-semi&comma nil nil)

My lack of elisp knowledge doesn't let me to help in fixing this issue.
I looked deeply for solution to this problem, unfortunately I didn't find anything but the advices of using mumamo instead. Well, I hesitate to accept this solution. nXhtml is a great package with a lot of features, but what i'm looking for is a simple multimode in a buffer which will let me jump between php, javascript and css in html document for indention and highlighting. Omitting the fact that nXhtml had insufficient performance without byte-compiling (i didn't try compiling it tbh) I don't like the idea of having one package for all tasks. Sorry if i misunderstood the role of nXhtml and mumamo package. 

P.S.
I can not vouch for the reliability of next words, but as far as i can remember, when i first installed and configured the package, i tried to write a file combined of html, php, css and javascript and it worked well including highlighting and indention. I can not remember if I changed something since that time, but now I'm having this annoying error just like the topic starter.

--
This message was sent on behalf of m.pontus@gmail.com at openSubscriber.com
http://www.opensubscriber.com/message/help-gnu-emacs@gnu.org/12975889.html




^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: The problem of writing php code with emacs, Help!!
  2010-03-28  0:27 ` m.pontus
@ 2010-03-29 20:28   ` Lennart Borgman
  0 siblings, 0 replies; 4+ messages in thread
From: Lennart Borgman @ 2010-03-29 20:28 UTC (permalink / raw)
  To: m.pontus; +Cc: help-gnu-emacs

On Sun, Mar 28, 2010 at 1:27 AM,  <m.pontus@gmail.com> wrote:
> Having the same problem. It may be better idea to put a bug into mmm-mode bug tracker, but if anyone is familiar with this problem, the solution would me much appreciated.
>
> I managed to get backtrace on error occurrence, here is what it says:
>  Debugger entered--Lisp error: (wrong-type-argument stringp nil)
>  c-syntactic-skip-backward(nil nil t)
>  c-looking-at-decl-block(nil t)
>  c-guess-basic-syntax()
>  c-indent-line()
>  c-electric-semi&comma(nil)
>  call-interactively(c-electric-semi&comma nil nil)
>
> My lack of elisp knowledge doesn't let me to help in fixing this issue.
> I looked deeply for solution to this problem, unfortunately I didn't find anything but the advices of using mumamo instead. Well, I hesitate to accept this solution. nXhtml is a great package with a lot of features, but what i'm looking for is a simple multimode in a buffer which will let me jump between php, javascript and css in html document for indention and highlighting. Omitting the fact that nXhtml had insufficient performance without byte-compiling (i didn't try compiling it tbh) I don't like the idea of having one package for all tasks. Sorry if i misunderstood the role of nXhtml and mumamo package.
>
> P.S.
> I can not vouch for the reliability of next words, but as far as i can remember, when i first installed and configured the package, i tried to write a file combined of html, php, css and javascript and it worked well including highlighting and indention. I can not remember if I changed something since that time, but now I'm having this annoying error just like the topic starter.


It is a bit unclear to me if you are using mmm-mode or nXhtml. If you
want to test nXhtml I just uploaded a new beta 2.07 which may fix your
problems.

Byte compiling nXhtml can be done from the nXhtml menu in Emacs.

For the problem that you do not wish to have everything in one package
I have no cure ... ;-)




^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2010-03-29 20:28 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-10-29  5:11 The problem of writing php code with emacs, Help!! Cheney Chen
2010-03-28  0:27 ` m.pontus
2010-03-29 20:28   ` Lennart Borgman
2010-03-28  0:29 ` m.pontus

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).