This question goes to people that really master DW, otherwise you probably would not now this question. I have some websites that pull the head via a php include in the server. Most of the CSS code is on that head so in the visual editor in Dreamweaver you dont see the text formatting and cannot even apply CSS styles to stuff in the website because it cannot read the head which is in a PHP path like this <?php require("/home/user/public_html/folder/header.php"); ?> The strange thing is that when I remove the /home/user/public_html And leave it like this: <?php require("/folder/header.php"); ?> DW will load the head and then I can normally edit the content with CSS styles. Of course leaving it like that will not work in the server. So I find myself having to edit this manually everything I want to apply a style just to revert it again before uploading it to the server. My question is. Cant I fool DW to not read the home/user/public_html path Or configure this in some settings in the Site path so it would work? Putting a local server is not an option as my remote server is highly complex and I dont edit pages to frequent so its justified. Its not a big issue to always have to edit the path but its just annoying and I though a software like DW should handle paths and routes fines. Of course I have to tell it to ignore it but how?
It sounds to me like you have differing folder structure on your server to locally because otherwise the paths ought to be the same and therefore allow you to edit the files in dreamweaver. Not sure how else this could be happening.
The path which includes the head should be in relation to the file which is "requiring" the header, so on your remote server it seems like the index.php file or whatever is outside the home/ folder? It doesn't seem right. Anyway, a solution may be to put your local files into similar directories (create a home/, user/, public_html/ folders and put the site in the last one) so the path is the same as remote. But as I stated before, if that is the case, the file which contains "<?php require("/home/user/public_html/folder/header.php"); ?>" has to be in the parent folder(in bold) containing the others /example/home/user/public_html/folder/header.php I hope I got your message right and I've helped ^^ Cheers!
Thats correct, the path in the local computer is the same starting at /public_html The full path of course isnt, because I cannot create a file structure in my windows PC like /home/domain/public_html/ In my PC its more like C:/websites/domain/public_html So Dreamweaver sees the root at /domain/public_html If I change on the code the full path to be /public_html its shows correctly but then it will not work in the webserver, there it needs the full path. So I find myself changing this each time I edit, then saving the file, so I can visually see the page, then before uploading I have again to revert it and upload it. The solution to this would be to trick Dreamweaver into believing or ignoring /home/domain Or making some kind of symlink in Windows. Windows file structure is different than Linux so this is the issue here.