PDA

View Full Version : Browser problems in cs4?


mac1967
04-08-2010, 02:54 PM
Hi Chaps!

I've been using CS3 for quite a while now and I suppose I've just gotten used to it...so this may be a really silly question.

I've recently loaded Dreamweaver CS4 and of course there is the new live view!! My problem is, when I go to view through my browser as I normally do (I have safari, explora and firefox) none of them work. It only shows a white page with all the content but none of the styling at all (it's like all the styling has been switched off like you can in firefox).

When I use CS3 agin and browse as normal, it's fine...but always with no styling in CS4.

What am I doing wrong please?

Regards,

Martin:(

dzwestwindsor
04-08-2010, 11:46 PM
how are you displaying it in your browser? are you clicking on the Globe in Dreamwevaer? or are you just opening the webpage normally (by click on the .html file and selecting Open with *** )?

mac1967
04-09-2010, 12:00 AM
Actually in Dreamweaver.

File> Preview with browser> select firefox, explora, safari. All with the same outcome. No style text and images on a plain white background. No styles at all??

Almost like in Firefox when you can view a page with "No style"????

I know you have the "live view" in dreamweaver now but I still like to view in diff browsers?

What am I doing wrong.

When I open the same doc in Dreamweaver CS3 the preview in browser works fine????

dzwestwindsor
04-09-2010, 12:55 AM
why not just navigate through your files and go to the exact file location (where your .html file is stored), and open the file with a web browswer? does that work?

if that doesn't, are you using CSS for styling and layout? make sure that the CSS sheet link tag is correct (path wise). also, are you using dreamwevaer templates? sometimes templates are glitchy... lol thats why i never use them

regardless, try navigating to ur html file first, and then right click and open with firefox, safari, etc

mac1967
04-09-2010, 01:30 AM
ok...I've tried going to the files and right clicking and opening in the various browsers but the same thing happens? No styling?

It does look like it's not looking at the styling??

If it works in CS3, wouldn't it be natural to assume it would work in CS4 without the need to change anything??

The thing is..its really handy to be able to preview direct from File > Preview in browser...I must be something wrong??

I am using CSS for syling and layout and I have created a master template myself (not downloaded) so I can change pages easily?

dzwestwindsor
04-09-2010, 01:43 AM
Ok... I remember having this problem a long time ago.

Now, if I'm not mistaken, you have to check over ALL of your paths again.

Because you are using templates, (stored in a Dreamweaver given Template folder) make sure that you're using absolute paths, and just check over all the paths.

Make sure that you are standing in the paths perspective of the template, which is in the folder.

So basically, try updating the template by making sure the paths are correct... for example--

if you have in a folder called Template and a maintemp.dwt, and all of your pages are using that maintemp.dwt IN that Template folder, make sure that the path for images or stylesheets are absolute, if it's not stored withen the template folder.

The best place to be doing this is in code view, because then you can see all the paths, and make sure that it is correct from the template's (in the folder) stand point.

Hopefully that makes sense, lol it might be hard to explain/comprehend, if it doesn't ill explain more :)

mac1967
04-09-2010, 01:50 AM
Oh bugger, I knew I get found out!!! (not very good...lol!).

I'm sorry I don't quite know what you mean?

Can you explain this a bit better please maybe with an example piece of code?

Why did it work before in CS3 and not CS4?

Thank you!

dzwestwindsor
04-09-2010, 02:04 AM
Hey no problem. lol lemme try my best

Ok.. so you have a template file that you created, yes?

Be default, the template file is in a folder called templates, and the template that you defined should be in that folder.

Now, you must have an images folder as well? you must have put that folder in your root directory. If you don't even have a folder for images, then you must have just plopped your images down in the root directory.

So lets say that you wanted to access car.jpeg using your template

Instead of just saying <img src = "car.jpeg"> You must say <img src = "/rootfolder/images/car.jpeg">

Because, if you just did <img src = "car.jpeg">, your browswer will look for the image car.jpeg directly in your templates folder (where you are calling that from). but obviosuly, it's not there. it actaully is in the image folder in the root directory, which is why you should do <img src = "/rootdirectory/images/car.jpeg>".


So basically make sure that you define the absolute path to the object or image that you are trying to access. otherwise, your browswer will look right in the templates folder (which has no pictures in it)


if you still don't understand, then read below-

This was taken from About.com-
------------------------

If you're referring to a Web element that is on the same domain that you're on, you don't need to use the domain name in the path of your link. Simply leave off the domain, but be sure to include the first slash (/) after the domain name.
For example, the Beginner's Resource Center has the URL: http://webdesign.about.com/library/beginning/bl_begin.htm If I were to link to this URL from another page on my site, I could link to it in this way:
<a href="/library/beginning/bl_begin.htm">...</a>



------------------------


the article is found here- http://webdesign.about.com/od/beginningtutorials/a/aa040502a.htm



And same goes with your stylesheet link tags. Make sure that it is the absolute path.



Or if you still dont understand, then google "absolute paths" and then read about them.

And if your error stil persists after this, then i really dont know what to do. :(

lol good luck, feel free to ask more questions if u want :)

mac1967
04-09-2010, 02:27 AM
Yep...I've checked all of the links to all the images and style sheets and they're all fine?

If this line of code said:

<link href="/brightegg.css" rel="stylesheet" type="text/css" />

Then I would expect it not to work because the css style sheet isn't in the same folder, but it says this:

<link href="/css/brightegg.css" rel="stylesheet" type="text/css" />

As you say telling it it's in the css folder. Like wise with all the images etc...

If I go to File > Edit browser list > and click "Preview using temporary file" I can actually preview that one page, but I can not go any further to check the links etc as I could before? If I do click further the style just disappears again!!! :mad:

I have not changed anything from using CS3...this is so confusing?

I now it's going to be some thing really silly!

dzwestwindsor
04-09-2010, 02:52 AM
lol i so wish i could help, because i had this problem before.

But back then it was because my paths were messed up.

I dont know wat to say ..... sory

I'm sure ull figure it out. change stuff around, dont be scared, sooner or later ull find out why :) good luck

dzwestwindsor
04-09-2010, 02:52 AM
and if u come up with other strange errors feel free to post again :)

mangofreak
04-09-2010, 03:56 AM
Try this:
<link href="css/brightegg.css" rel="stylesheet" type="text/css" />

instead of:

<link href="/css/brightegg.css" rel="stylesheet" type="text/css" />

can you post your code?

DWcourse
04-09-2010, 04:41 AM
I believe if you set your preview in browser preferences to preview using temporary file, it will take care of the problem.

Another solution is to always use document relative links (../file.css) to your css and javascript in templates.

(Or I might have that completely backwards)

mac1967
04-09-2010, 09:15 AM
You're right, It does solve the problem if I set my browser preference to preview using temporary file but ONLY to the first level of checking links. If I browsed it then clicked another link all the styling would disappear again??

Do you know...

I have a sneeky suspision I have changed something when I changed my host.

I set up the new site on CS4 and in "Manage Sites" > links to relative: site or document. I'm sure it went wrong there somehow??