thanks, that really helped 🙂

It's connecting to the database now, however I have a slight problem. When it runs it runs with the following filepath:

http://localhost/BeginningPhp[/B]createmovie.php

And that causes an error because it is meant to go to: /createmovie.php instead. Is there a way to fix this?

Also, would you know how to do the same thing to NotePad++
Just I've been playing around with different editors and this one has a very handy auto-complete which is sadly a function that Crimson Editor doesnt have

    Haha, it's funny you say that, because once I posted that, I made it for notepad++ and fixed the backward slash issue.

    header('Location: ' . str_replace(array('d:\\xampp\\htdocs\\','\\'),array('','/'),strtolower(stripslashes($_GET['loc']))));
    

    To add it in Notepad++:

    Press F5 (or go to Run -> Run...) and type into the box:

    firefox "http://localhost/run.php?loc=$(FULL_CURRENT_PATH)"

    And then click save, and save it as you wish.

      Hey,

      I'm still getting the following error:

      http://localhost/BeginningPhp\createmovie.php

      The backwards slash...

        It shouldn't be if you changed the PHP code of run.php, as it does a str_replace and replaces '\' (escaped backslash) with '/' (forward slash).

        It is only a quick hack, and you should be able to modify run.php to take the path that it is given by the editor, and manipulate it how you want before forwarding to whatever page it is you need.

          Hey, the hack for Crimson Editor works fine, but Notepad++ doesn't work. All I did was add the:

          firefox "http://localhost/run.php?loc=$(FULL_CURRENT_PATH)"

          , i didn't do anything with the run thing for Notepad++.

          Sorry bout this 🙁

          Also, would you know if it is possible to make Notepad++ do what Crimson Editor does by highlighting the whole line. Just I'm used to that from VisualBasic and DarkBasic (via Darkedit) and it's kinda a thing of habit.

          Thanks

            Zend Studio highlights lines. 😉

              uh, so does Crimson Editor. But NotePad++ has the possibilty to be an awesome FREE, auto completing, highlighting coding environment... that is if I can get some help with fixing the backwards slash issue (pretty please madwormer2)

                In the run.php file, replace the code with

                <?php
                if (isset($_GET['loc'])) {
                  header('Location: ' . str_replace(array('d:\\xampp\\htdocs\\', '\\'), array('', '/'), strtolower(stripslashes($_GET['loc'])))); 
                }
                ?> 
                

                If that doesn't work, let me know what the error is.

                I'm not sure what you both mean by "highlight lines"? It's sort of ambigous.

                  madwormer2;10880689 wrote:

                  I'm not sure what you both mean by "highlight lines"? It's sort of ambigous.

                  See attached.

                    From what I can see, Crimson Editor lacks this feature also. He must mean something different.

                      Yes, I mean the same thing as in Crimson Editor.

                      Like when you are typing in line 3 of the editor it highlights the whole row, so you can differentiate that row from everything else.

                      Like this:[ATTACH]3613[/ATTACH]

                      EDIT - Thanks php database files now run, thanks heaps 🙂

                        Not to worry I fixed NotePad++, and it looks awesome now 🙂

                        Just for other people who might be interested, everything in NotePad++ is customisable to your liking. To change just about anything go to:

                        Settings>Styler Configurator>Global Styles (This affects everything)

                        From there you can edit the Current Line Background to make it highlight the current line, as well as just about anything else. You can change language specific highlighting by choosing the language you want to use.

                        Thanks all for helping me with this 🙂 (particularily you mad 😉)

                          Your welcome.

                          I was thinking that was what you meant, but then you said that notepad++ didn't have it, and it threw me completely because I have that feature enabled, and am pretty sure it came enabled.

                          If all is well, you can "Mark thread resolved" under thread tools.

                            Write a Reply...