31 Replies Latest reply on Jan 7, 2012 12:46 AM by Steveorevo

    Wordpress, Dreamweaver CS5, XAMPP...

    highwaykind Level 1

      I set up XAMPP as my local testing server using this excellent walkthrough


      I synced my website so I had all the right files, and moved the folder into xampp/htdocs


      I'm pretty sure everything went right, because if I creathe the sample php file that shows the current time/date (as instructed in the walkthrough) in my website folder, everything is working fine.


      I set the Site specific code hinting to Wordpress, with everything as recursive scanning.

      But when I click on index.php DW complains that I have to click "Discover" and then in the same small top bar, it complains about a Server error.


      Help please... I was really looking forward to not having to 'live' test my adjustments - did I forget to do something to get Wordpress to work in Dreamweaver CS5?

        • 1. Re: Wordpress, Dreamweaver CS5, XAMPP...
          mcmattp Level 1

          I am having the exact same issue, but it's on Joomla.  I followed the same tutorial, I set up the XAMPP.  I synced my files between my local folder, my testing etc.


          My issue varies here slightly and when I click on "Live View" of my local setup site (XAMPP running correctly) it says "database error:can't connect to the mysql_database".  Here is where it's weird:  If I go to the "database" connection on my index.php file and set up for my local XAMPP server to connect to the mysql database for the site, it says "Connection Made" and there are no errors in connecting to the mysql database.  I can even see the mysql database tables in the browser and view information about them.  If I try to view the index.php file in DW I get the the same "database error: can't connect to the mysql database" EVEN AFTER IT JUST CONNECTED IN THE MYSQL DATABASE.


          This is really causing some confusion.  The tutorial does talk a bit about creating a NEW mysql database and PHP files etc. but it does not talk about importing the mysql database from an existing Joomla or Wordpress site (which will also have mysql table associated).  Using the XAMPP server I take it is simply like making a new copy of the files and structure, as well as the mysql database, to run on your computer locally.  That's why I am super confused as to how I can see it connect to the db fine in DW but when I view the index.php within DW it says it cannot connect to the DB.


          From what the OP is saying, you didn't import your DB with phpmyadmin?  Is this not a required step?  So far using Dreamweaver on an existing Joomla site is extremely difficult and time consuming, so much so, that it has taken my about 6 hours of trying and failing and troubleshooting and have gotten nowhere.


          Has anyone got this working?  I haven't really heard of any success stories on Joomla.  Regardless, sorry for the lengthy post any help would be appreciated.



          • 2. Re: Wordpress, Dreamweaver CS5, XAMPP...
            Bob Timms Level 1

            I have been able to work in Joomla, WordPress and Drupal using Xampp  - not without some speedbumps but not DW related. In Joomla you should check your configuration.php in the root directory and verify that Joomla knows all the correct site paths and server. 99% of problems I have had in the past connecting to a database could be resolved in this file.

            • 3. Re: Wordpress, Dreamweaver CS5, XAMPP...
              mcmattp Level 1



              Thanks for the reply.  At this point I am on day 2 of trying to get the program to "work".  Any specifics you could lend would be helpful.  A couple of questions:


              1.  Was I correct in exporting my mysql database and then importing into my http://localhost phpmyadmin???

              2.  In the configuration.php file, what specifics have worked for you with Joomla?  (I just switched the username to "root" and put the local database name in there, but still it did not work)

              3.  Does it always take 2 plus hours to "sync" a Joomla site?  I use hostgator, but this is SLOW.


              I have spent sooooo much time trying to get this to work and I can't find any decent documentation that follows you through the steps to get it working well with Joomla.  I really hope it's worth the two days I've wasted.




              • 4. Re: Wordpress, Dreamweaver CS5, XAMPP...
                Bob Timms Level 1

                I'll do the best I can come up with.To start with I have been running some version of apache/php/mysql for about 6 years so I have made customizations to my configuration that will not be like yours. Specifically, setting the server directory to something other than the default htdocs assigned by apache. If you are using the default configuration you must use this directory for your site. To your questions:


                1. Yes, export from the original db and import to the new/working db.

                2. When you create the database or import it your have to enter a username/pw which MUST agree with your configuration file. My suspicion is this is where the conflict is - your webserver directory as created in DW and the one in the config file do not agree or there is a conflict with your username/pw.

                3. Most all sites I do are DB driven - so I use a commercial product to sync databases in realtime and it usually takes less than 1 min. However I used to use phpmyadmin to import/export but most of the time took only a few minutes.

                • 5. Re: Wordpress, Dreamweaver CS5, XAMPP...
                  mcmattp Level 1

                  Update:  I edited the configuration.php file and seemed to have correctly put in the database name, as I no longer get the error that it can not connect to the database.


                  Now when I visit the site in live mode (index.php of the site) I get the awesome error that many others are getting:


                  dynamically-related files could not be resolved because the site definition is not correct for this server.



                  If I try to visit the local site by going to http://localhost/FOLDER


                  I simply get a blank screen.  Does it really have to be this difficult?  REALLY?




                  • 6. Re: Wordpress, Dreamweaver CS5, XAMPP...
                    mcmattp Level 1

                    Bob:  The database isn't what is taking 2 plus hours.  It's when I sync the "local files" within DW to the files on my FTP hosting server.  To get duplicate files of ONE Joomla site takes about 2.5 hours and in that time I can't do a whole lot with Dreamweaver.



                    • 7. Re: Wordpress, Dreamweaver CS5, XAMPP...
                      Bob Timms Level 1

                      I think you are getting there. I can't help much with DW file synchronization - I have always had some issues with DW ftp and use another (commercial) ftp program.There are many good ftp programs - I only use a commercial one because I need to transfer from 1 remote site to another remote site and not have to download them to my local pc.

                      • 8. Re: Wordpress, Dreamweaver CS5, XAMPP...
                        mcmattp Level 1

                        I can't figure it out.  I can't find help anywhere.  I need to give up before I break something.  I want my money back...

                        • 9. Re: Wordpress, Dreamweaver CS5, XAMPP...
                          highwaykind Level 1

                          mcmattp wrote:



                          This is really causing some confusion.  The tutorial does talk a bit about creating a NEW mysql database and PHP files etc. but it does not talk about importing the mysql database from an existing Joomla or Wordpress site (which will also have mysql table associated).


                          From what the OP is saying, you didn't import your DB with phpmyadmin?  Is this not a required step?



                          I completely agree that this might be working well for a NEW site you're creating, but it really is not working for an existing site that you're trying to import.


                          And: Er.. huh? Import my Wordpress existing DB with phpmyadmin..that wasn't in the walkthrough, so nope, I didn't do that. Just putting all the folders there isn't enough..?


                          I did set up the Wordpress site myself, so I have full access (as well as access to the hosting server).

                          So I'll have to figure out how to do that today

                          Thanks for the hint! I'll see if I can export the database from somewhere.. More to come.

                          • 10. Re: Wordpress, Dreamweaver CS5, XAMPP...
                            highwaykind Level 1

                            Database successfully exported from server, imported into localserver (only took 5 attempts )

                            I changed wp-config so it has the username root and the password belonging to root.


                            It's working better - I can open wp-config.php, hit discover and not get any errors (and it shows a bunch of files at the top as well)

                            But when I open index.php (I should open the one in the Theme folder, right?) I can hit Discover and it works(as in: no errors, but also no bunch of files at the top), but when I hit live view get


                            Fatal error: Call to undefined function get_header() in C:\xampp\htdocs\sitename\wp-content\themes\mystique\index.php on line 3


                            Have to do some work now, back to tackle this thing later tonight I  think.. (and I hope someone will post another brilliant suggestion here  before that)

                            • 11. Re: Wordpress, Dreamweaver CS5, XAMPP...
                              Bob Timms Level 1

                              You should open the index.php from the root directory of the site - not the theme folder.

                              • 12. Re: Wordpress, Dreamweaver CS5, XAMPP...
                                LonelyDead Level 1

                                I used this to set up my Xampp and wordpress

                                and this to set up my server in dreamweaver,


                                It worked perfectly,
                                The only problem i had was that i forgot to run
                                mysql and apache on the server,

                                but once i did that it was sorted.

                                This was my first time setting up a server and

                                wordpress so anybody should be able to get

                                it if i can.


                                • 13. Re: Wordpress, Dreamweaver CS5, XAMPP...
                                  highwaykind Level 1

                                  Feared as much, but that one doesn't work (yet?) Thanks for clearing it up though.. when something's not working I start doubting everything.

                                  • 14. Re: Wordpress, Dreamweaver CS5, XAMPP...
                                    highwaykind Level 1

                                    Thanks for the link!

                                    I seem to have everything set up correctly since when I go to


                                    It tells me:

                                    You appear to have already installed WordPress. To reinstall please  clear your old database tables first


                                    So I think I can skip that walkthrough?


                                    When I open the index.php in my root folder (above the licence.txt file in Dreamweaver) I still get


                                    Dynamically-related files could not be resolved because the site definition is not correct for this server retry/setup


                                    Setup sends me to the site definition setup (and since 'testing.php' in the same root folder IS working -- not linked to Wordpress site, just a file with <p>The time is now <?php echo date('H:i:s'); ?>.</p> inside - - I think I've set it up all right?)

                                    • 15. Re: Wordpress, Dreamweaver CS5, XAMPP...
                                      LonelyDead Level 1

                                      I had the same error when i first started,

                                      but it was because i put the site in the wrong htdocs,

                                      you're meant to put it in the htdocs in the xampp folder,

                                      but i put mine in the first htdocs you see when you check

                                      your C:

                                      Then i put it into the htdocs of xampp and fixed the definitions

                                      in dreamweaver so they went to the right folder and mine worked.

                                      This was a silly mistake by me though because i didn't

                                      know what i'm doing so i don't think anyone else would do it lol.

                                      But just saying just in case.

                                      Otherwise i don't have a clue about yours.


                                      • 16. Re: Wordpress, Dreamweaver CS5, XAMPP...
                                        Virgil Palanciuc Level 1

                                        There are three distinct issues here:

                                        1. The "related files" error may be caused by the fact that your local setup is not working (see below); but I think this error most likely tells you that the site does not have a testing server correctly configured in dreamweaver. See this tutorial for how to define your testing server: http://tv.adobe.com/watch/learn-dreamweaver-cs5/simplified-site-setup-in-dreamweaver-cs5/ (roughly at minute 2:40)

                                        2. Live view - Whether this is working/not working, it mainly shows that you have (or have not) set up the local ("testing") environment - with Apache, Mysql correctly running, passwords configured & everything.... basically that your CMS works in the local setup. Check that you can see your (local) site in a browser... and if you can, check that the testing server configuration (from point 1 above) is  correct & complete.

                                        3. Site-specific code hints: as the name says, it's all about codehints (PHP codehints, in particular!). It doesn't matter how and if you have configured your site - you basically tell dreamweaver where to look for relevant codehints. This configuration will only impact your ability to see codehints, and has nothing to do with "related files" of "live view" (e.g. you can get a "related files" error and still see the "related hints"  correctly - or viceversa, getting dynamic related files to work does not guarantee that you'll get hints from those files, you must have the "site-specific codehints" configured).


                                        Hope that helps.

                                        • 17. Re: Wordpress, Dreamweaver CS5, XAMPP...
                                          highwaykind Level 1

                                          OK, with pictures now...


                                          @Virgil - The video you are linking to does not seem to give any new iof different information compared to the walkthroughs above...



                                          I really don't think I've incorrectly set up the testing server. I used the walkthrough which was really good, and more importantly: I've got green checkmarks in the setup, and it's working for my testing.php file :



                                          Since the testing.php file works perfectly fine, I think the testing server settings must be correct ( testing.php is in the same folder as the rest of the wordpress stuff.I just added it later to test the testing server. The problem seems to be the interaction with something Wordpress related, but I can see on the local server in firefox that Wordpress is installed correctly..)


                                          It doesn't seem to matter if I browse things Locally, or inTesting  server mode (in the Files area on the right you can choose  Local/Remote/Testing/Repository)


                                          This is my testing server setup.

                                          (Igore the rest. Someone told me I should open the index.php file in the root, but I think maybe they're wrong since isn't it the index.php in the active theme folder (in wp-content, themes, mystique(in my case) that it's actually loading when you go to the URL? At least that is the file that refers to the main content and the sidebars etc..)




                                          But when I open the index.php in the wp-content folder  (in my active theme folder)  I get a fatal error (I get a fatal error, not always the same one, for every other php file I open from that folder ) and when I hit Discover for those, no other related files will appear in the top bar either.



                                          Ican successfully Discover and Live view the index.php that's in the wp-admin folder (haven't tried logging in yet).

                                          (The CSS files get added when I hit "Discover" so at least it's doing something!).




                                          I'm really glad I'm using the 30 day trial version..

                                          If I can't get this working I might not buy CS5 at all, and just stick with my current CS4...(this CMS/live option was the main reason I was going to upgrade..seemed like it was going to be much easier to adjust wordpress themes..)


                                          I hope with these pictures things are clearer, and I hope that someone can figure out why some parts are working, and some parts aren't?

                                          • 18. Re: Wordpress, Dreamweaver CS5, XAMPP...
                                            Virgil Palanciuc Level 1

                                            You must use the "main" index.php file for it to work; basically, it's the same as it would be in the browser... if you paste the URL and it doesn't work in an external browser - then it won't work in DW either.

                                            For Dynamically-related files... I don't know for sure if what you're trying to do is supposed to work .

                                            The way DRF works is that it "instruments" your page with some additional code, then posts the page to the testing server, and queries it to get all the included files. But if your page is actually just a small piece of code that doesn't work on its own (it is only meant to be included in other pages - e.g. as is the case with your theme's "index.php" file, which gets included in the "main" index.php file) - then related files discovery may fail, since the server isn't able to interpret that page on its own (or at least that's my understanding of this feature, I didn't work on it myself, so there's a chance that I may be wrong).


                                            I *think* the suggested workflow for editing WordPress themes is to start from the main page, and then navigate using live view & css inspect + edit the "theme files"  in codeview as "files related to the main index.php", not as "primary entry-point files".  But then again, I'm not an expert on this by any means. There is a tutorial on adobe.com about editing wordpress themes - see http://www.adobe.com/devnet/dreamweaver/articles/creating_wordpress_theme_with_dreamweaver _pt2.html (I must admit I didn't read it myself, but nevertheless I expect it to explain the typical workflow )


                                            Hope that helps,


                                            1 person found this helpful
                                            • 19. Re: Wordpress, Dreamweaver CS5, XAMPP...
                                              highwaykind Level 1

                                              Thanks Virgil!


                                              I figured I didn't neccesarily have to edit a theme from within the existing site.

                                              So I just did a clean Wordpress install on the testing server, and now the main index.php is Discovering and Live viewing fine.

                                              And since I can 'live' navigate within Dreamweaver I should be able to adjust the theme for specific pages (eg - theme options that don't affect the main page) as well..


                                              So, although it's a bit of a hassle, it should be working for theme adjusting (but still not for existing pages).


                                              I'll read the link you posted later, I figured the whole WP theme CSS/PHP editing thing out on my own, and I'm sure I missed a few things here and there, so a complete overview could be very helpful!

                                              • 20. Re: Wordpress, Dreamweaver CS5, XAMPP...
                                                Virgil Palanciuc Level 1

                                                I made a bad mistake - linked to the wrong tutorial. (it was for CS4)

                                                Working with a CMS in CS5 is demonstrated here:  http://xpressabhi.com/adobe-dreamweaver-cs5-video-tutorial-collection/ (first video )

                                                1 person found this helpful
                                                • 21. Re: Wordpress, Dreamweaver CS5, XAMPP...
                                                  highwaykind Level 1

                                                  I think I've got things working.

                                                  Turns out all the Wordpress entries/pages/menu items are stored in the database, so simply installing Wordpress on the server and importing all the folders/files from the site wasn't enough to get the menu etc in place (it would only show the default).


                                                  Exported Wordpress database from site server, imported it into localhost server.

                                                  I still can't open the index.php from the root (but I can open and discover for instance wp-config.php).


                                                  But I can "live" navigate my Wordpress site on my localserver and within Dreamweaver, and so I can adjust the CSS for those pages which was what I was going to use it for.

                                                  I'd better start saving up again, my local store would have CS5 in stock in June. 27 more trial days left, I should be OK.

                                                  • 22. Re: Wordpress, Dreamweaver CS5, XAMPP...
                                                    GatlingNJC Level 1

                                                    Hey, Has anyone been able to utilize the live-view/inspect mode to edit their css on a using the live/remote server?



                                                    I need help!

                                                    • 24. Re: Wordpress, Dreamweaver CS5, XAMPP...
                                                      IMWEBGUY Level 1

                                                      The Dreamweaver server path is c:\xampp\apache\htdocs\.....


                                                      check the server with an index.php file, containing " <?php phpinfo(); ?> "   Place this file in the local site location defined in dreamweaver.  Run live view and  the phpinfo page should show.


                                                      Then make a sub folder in the htdocs folder to place your Word press template then add that folder to the dreamweaver server path.


                                                      Your off and running now

                                                      • 25. Re: Wordpress, Dreamweaver CS5, XAMPP...
                                                        dog45mike Level 1

                                                        I have been trying to open up and edit a wordpress theme on dreamweaver CS5 for 2 weeks now and despite the videos the tutorials and the advice given on this thread I still cannot do it to save my life.


                                                        please can someone who has managed to open up and edit a wordpress theme in dreamweaver CS5 please put up the step by step process how they got it to work.


                                                        It would be very greatly appreciated


                                                        thank you

                                                        • 26. Re: Wordpress, Dreamweaver CS5, XAMPP...
                                                          GatlingNJC Level 1

                                                          Hello Mike,
                                                          What do you mean by "open and edit"?

                                                          Are you trying to edit your WP site remotely?  If so, you can do this, but the full extent of live view and inspect mode is not available.
                                                          If you are trying to transfer an existing site to DW and set it up locally, then that is a little tricky and I have not seen anyone suggesting or offering instructions to do so.
                                                          I hear your frustration.  Don’t worry, if you’re 2 weeks into it; you are not far from obtaining a solid familiarity with the set up:)  I’ve made some posts regarding my experience integrating DW & WP using MAMP(I’m on a Mac). I am not sure what extent you are trying to edit or where you are stuck on your integration. You can check out my posts:


                                                          I followed the Lynda.com video tutorial to the tee, but ran into problems when it came to setting up my remote database and server.
                                                          If you are stuck, I strongly recommend getting some help from: http://www.webphysiology.com

                                                          Jeff knows WordPress well and knows development language well.  I hired him for a couple hours to help me finish my DW & WP integration.  He coached me through the process over Skype.


                                                          I use BlueHost and I did Not instal WP on BlueHost with their “simple scripts” tool. I created the MSQL database on the remote server then I uploaded WP directly into the BlueHost root directory files.  Then I did some configuration with Jeff.  A helpful hint is to name the local database the same as you will on your server database.
                                                          I hope you find some strengths in your learning process.


                                                          On an encouraging note, I had NO knowledge of css, DW, or WP before I began my site integration.  I gained a huge amount of knowledge from my experience and have been able to make some small css edits to my site in DW.  You can check my site, which I will continue to fine tune: http://www.5ing.us





                                                          • 27. Re: Wordpress, Dreamweaver CS5, XAMPP...
                                                            LonelyDead Level 1

                                                            I'm going to guide you through, step-by-step as i do it right now
                                                            on a windows laptop.
                                                            And testing files locally.


                                                            Firstly i'm guessing you  already have XAMPP installed.
                                                            if not, go and do it now.
                                                            Open up your copy of XAMPP and press 'start' on both 'apache'  and 'mySQL' otherwise your
                                                            local hosting won't work.


                                                            In your browser type in: http://localhost/xampp

                                                            on  the left navigation go down to phpmyadmin

                                                            click on it, if  you have a username and password type it in,
                                                            if this is a new install and you haven't made a password then you'll be  into the phpmyadmin interface,

                                                            Below where it says 'My SQL  localhost' type in a name for your database then click 'create'.

                                                            You're  database for wordpress has been created.


                                                            Next go to http://wordpress.org/download and download a copy of the latest wordpress(currently 3.0.5),

                                                            save  it to your desktop then extract all.


                                                            Open up the  extracted wordpress-3.0.5 folder, inside there is a folder called just 'wordpress',

                                                            copy  or rename the 'wordpress' folder to the name you want your site  to be. 'yoursite'.

                                                            Keep the 'wordpress-3.0.5' folder open  while we do the next bit so it looks like this:



                                                            Open  up your computers 'folders' and browse to you XAMPP htdocs folder:




                                                            With both folders open drag the 'yoursite'  folder over to the XAMPP htdocs folder

                                                            so it will now look  like this and your 'wordpress-3.0.5' folder will be empty:




                                                            Open  up your browser and type in: http://localhost/yoursite

                                                            If  everything is correct you should get a wordpress error page,

                                                            it  tells you to create a configuration file,

                                                            go ahead and press 'create  a configuration file' then on the next page press 'lets go'

                                                            On  the next page you enter your database info that you created earlier.

                                                            Database  name: yourdatabase

                                                            Username: root

                                                            Password: leave it blank


                                                            Leave the rest as they  are and then press 'submit'.

                                                            You should get to the next  page now then press 'run the install'

                                                            On the next page  enter the info you want.


                                                            Now it's time to get it all  working in dreamweaver.


                                                            Open up dreamweaver:

                                                            Site>new  site

                                                            The site definition box will open up:


                                                            sitename:  yoursite

                                                            local site folder: C:\xampp\htdocs\yoursite\


                                                            On the left in the  site def box go to 'servers'

                                                            click on the '+' to  add a new server


                                                            servername: yourserver

                                                            connect  using: local/network

                                                            server folder: C:\xampp\htdocs\yoursite

                                                            web  url: http://localhost/yoursite/

                                                            click on the  advanced tab, at the bottom change 'testing server'

                                                            to PHP  MySQL

                                                            Click on save, then save again to get out of the  site def box.


                                                            All the wordpress folders and files  should now appear in your dreamweaver,

                                                            open the first index.php,  in the window click on 'Discover' related files.

                                                            Then  change dreamweaver to 'live view' and you should be able to see yoursite.



                                                            • 28. Re: Wordpress, Dreamweaver CS5, XAMPP...
                                                              dog45mike Level 1



                                                              sorry I should have been more clear in my post yes Ive installed XAMPP  (laptop is on windows 7) and set up a local server.


                                                              my problem is when I hit live view I get the folllowing:


                                                              Fatal error:  call to undefined function get_header() in C:xampp\htdocs\wp-content\themes\twentyten\index.php online 16



                                                              I know  someone earlier on in this thread had the same problem but I dont seem to be able to overcome this


                                                              but later on tonight or tomorrow I will go through Daniels post above step to step


                                                              many thanks for taking the time to post a reply to this,  it really is much appreciated  

                                                              • 29. Re: Wordpress, Dreamweaver CS5, XAMPP...
                                                                LonelyDead Level 1

                                                                You'll be annoyed at this one.

                                                                You are opening the index.php for the twentyten theme,

                                                                you have to open the wordpress index.php.

                                                                If you have all the folders closed in dreamweaver then
                                                                the index.php you should open is right below the wp-includes folder,

                                                                when you open it and discover, then live view, you

                                                                should get the live site



                                                                • 30. Re: Wordpress, Dreamweaver CS5, XAMPP...
                                                                  dog45mike Level 1

                                                                  Yep its all working now (sigh of relief) 


                                                                  I`m now on a role with the editing


                                                                  Another question I have now is once I have finished editing how is it best to transfer it onto a host`s remote server so it is live on the internet?


                                                                  (forgive me if my terminology is incorrect I`m still in the learning process)


                                                                  Thanks again for the help




                                                                  • 31. Re: Wordpress, Dreamweaver CS5, XAMPP...
                                                                    Steveorevo Level 1

                                                                    Use ServerPress.com's spin on XAMPP. It will enable LiveView directly on just the theme template page parts for realtime feedback. You don't have to flip back to the browser every 5 seconds or index.php in the root. Plus, you can click on the elements in LiveView and see the code associated with it in Code view.


                                                                    It also automatically generates a site definition file for you so you don't have to guess the settings, manage multiple projects, yadda yadda


                                                                    Pretty snazzy, ehh?