PDA

View Full Version : Problem uploading Gif files...



nick106b
05-25-2006, 04:21 AM
Hi all,
I've been uploading images to my public.html folder, but they didn't show on the pages. So I went into public.html/images folder - uploaded into that, and got the same result. What am I doing wrong? (This time...!)
TIA, Nick.:confused:

Early Out
05-25-2006, 07:24 AM
Where are the pages expecting to find them? If the call in your html is, for example:

<img src="mylogo.gif">

then the .gif file needs to be in the same directory as the html file. If the call is:

<img src="mypics/mylogo.gif">

then the .gif file needs to be in the "mypics" directory directly beneath whatever directory the html is in.

nick106b
05-25-2006, 09:17 AM
No mypics folder.
The Images folder was in the Public HTML directory and I thought the gif's should have been picked up from there. When they wer'ent I put them back in the public html folder - but they still did not show.:confused: So where do I go from here. This is using cPanel, by the way...

Early Out
05-25-2006, 09:30 AM
You're not getting this. Somewhere inside the html code for your webpage, the page is pointing to the image files. Those files need to be whereever the html code is pointing to. Without seeing your html code, I can't tell you where that is. I was just using "mypics" as a hypothetical example.

You have to open up the webpage file, and find out where it thinks the picture files are. Whereever it thinks the .gif files are, that's where they need to be, or it won't be able to find them!

nick106b
05-25-2006, 10:13 AM
The pages point to a sub-folder "AB New" where all the gif files are.
I really do not understand why they do not show when I upload them.
They do show in the cPanel public html folder, so they should show on the individual pages. Or am I missing something? (Still!):confused: :confused:

areidmtm
05-25-2006, 10:28 AM
Post your HTML code. We really can't help you much more if we're kept in the dark

Early Out
05-25-2006, 10:31 AM
Mystery solved!! Folders (directories) on the server can not have names with spaces in them, so "AB New" is going to fail on uploading. Same rule for filenames.

To keep yourself from getting wrapped around the axle, the best practice is to restrict your file and folder names to a-z, 0-9, dash (-), and underbar(_). Don't use any spaces or other special characters.

I'd keep it all lowercase, too - no capital letters. Why? Because file names on the server are case-sensitive. "Mydog.jpg" and "Mydog.JPG" and "mydog.jpg" are three different files. If you stick to lowercase all the time, you won't get confused (been there, done that :D ).

So, rename everything in the folder on your PC where you're building your pages to follow these rules, then rebuild the pages and upload them.

nick106b
05-25-2006, 12:50 PM
:( EARLY OUT you are still missing the point.
These gif files are from a 'resell' file copied into Frontpage. All the gif's were saved into a folder on my hard drive "AB NEW". This is a sub folder to my "Webs" folder, where the pages of this site are stored.
All the gif's are in lower case, some with _ underscores in the titles... But - that is not the problem. Its when I load them into my 'public/html' fo;der in cPanel, because whether I load them into the 'public/html' or into the sub-folder 'public.html/images, they do not show on the uploaded pages - even after "refresh". Does that clarify my case?
I'm green, but not that green... Cheers, Nick.

lazynitwit
05-25-2006, 01:04 PM
Mystery solved!! Folders (directories) on the server can not have names with spaces in them, so "AB New" is going to fail on uploading. Same rule for filenames.

To keep yourself from getting wrapped around the axle, the best practice is to restrict your file and folder names to a-z, 0-9, dash (-), and underbar(_). Don't use any spaces or other special characters.

This is not true, you can have spaces in directories and filenames. If they are having a problem uploading, it may be an issue with the program you are using. I do agree that you should not use spaces in files/directories though.


:( EARLY OUT you are still missing the point.
These gif files are from a 'resell' file copied into Frontpage. All the gif's were saved into a folder on my hard drive "AB NEW". This is a sub folder to my "Webs" folder, where the pages of this site are stored.
All the gif's are in lower case, some with _ underscores in the titles... But - that is not the problem. Its when I load them into my 'public/html' fo;der in cPanel, because whether I load them into the 'public/html' or into the sub-folder 'public.html/images, they do not show on the uploaded pages - even after "refresh". Does that clarify my case?
I'm green, but not that green... Cheers, Nick.
The folder should be public_html unless you are uploading them to a sub-folder within that folder.

Early Out
05-25-2006, 02:37 PM
I surrender, nick106b. You clearly understand the problem better than I do. Hope you find a solution.

areidmtm
05-25-2006, 02:56 PM
You know, it's kind of funny how people come here complaining that they don't know what they are doing and when we offer help to them, they become defensive and say that we're wrong.

We have tried to help you as much as we can while being left in the dark on how your code is written and without more information. Like I said before, for us to give you more accurate help, we'll need to see your HTML and how you're linking the images. If you're not going to work with us, then how are we supposed to work with you? and as Early Out said, I hope you find your solution.

Early Out
05-25-2006, 03:03 PM
This is not true, you can have spaces in directories and filenames.Right you are! I was thinking of the Comcast web servers, where this is a definite no-no, and an endless source of newbie problems.

Maggilove
05-25-2006, 03:34 PM
The pages point to a sub-folder "AB New" where all the gif files are.
I really do not understand why they do not show when I upload them.


:( EARLY OUT you are still missing the point.
These gif files are from a 'resell' file copied into Frontpage. All the gif's were saved into a folder on my hard drive "AB NEW". This is a sub folder to my "Webs" folder, where the pages of this site are stored.
All the gif's are in lower case, some with _ underscores in the titles... But - that is not the problem. Its when I load them into my 'public/html' fo;der in cPanel, because whether I load them into the 'public/html' or into the sub-folder 'public.html/images, they do not show on the uploaded pages - even after "refresh". Does that clarify my case?
I'm green, but not that green... Cheers, Nick.

Please clarify... did you upload the sub-folder, or just the gifs that were stored in the sub-folder?

KVN
05-25-2006, 04:46 PM
Nick

ignore the public.html/images directory.

If I understand you previous posts, your have a 'web' root directory on your home machine.
Within this 'web' directory your have an 'AB new' directory where you store your gifs.

when you upload your site from your local machine, make sure you maintain the directory structure - exactly - as it is on your home machine.

Uploading to public_html is the norm for most BH users (which basically means - upload everything in your 'web' root directory into the public_html directory.. including your sub folders)

If you do this and your images are STILL not showing up... I would suggest you check that frontpage is configured to ensure 'Relative' mapping as opposed to 'Absolute' for images and pages.
(I don't use frontpage so I don't know exactly how they refer to this.. )

A quick way to check if mapping is relative is to check any HTML file what you know has an image in it.. check to see how the Image is referenced.. if has a 'c:\web\ab new\image.gif' then that's a problem.. it should read '/AB new/image.gif'.

hope this helps.

If it doesn't then I suggest you cut and paste some code from an HTML file in your root directory (e.g. your Web directory) that has an image in it.
Should be easy enough 4 us to work it out from there.

ps. it IS bad practice to use the space character in directory names...

cheers

kvn

nick106b
05-26-2006, 02:23 AM
Got pulled away yesterday...
Ok, to clarify, as best I can. I've got "webs" folder containing all my site html pages. I copied and pasted into Frontpage a 'resell' page with a stack of gif images. These got saved by Frontpage into a sub-folder of "Webs" called "AB New". Previously, I have been able to upload images from this folder into my cPanel 'public.html' folder without any problem...
Here's a sample of the page's html:
<td vAlign="top" align="middle" width="28%" height="121"><b>
<font face="MS Sans Serif" color="#ff0000" size="2">
<img src="AB%20NEW/thoughts.jpg" border="0" width="182" height="229"><br>
Value:$50.00<br>
&nbsp;</font></b></td>
<td width="67%" height="121"><font face="MS Sans Serif" size="2"><b>
<u><font face="verdana,arial,helvetica">Self-publish at the Speed of
Thought</font></u><br>
</b></font><font face="Arial" size="2"><i>by Wayne Perkins &amp; Tom Hua</i></font><font face="MS Sans Serif" size="2"><b><br>
</b></font><font face="MS Sans Serif" color="#000000" size="2">Best
Selling Title from </font>
<font face="MS Sans Serif" color="#ff0000" size="2">Amazon.com</font>
<p><font face="MS Sans Serif" size="2">Learn how to self-publish
your <b>thoughts</b> and your <b>eBooks</b> with the <b>best </b>
selling eBook <b>author</b> and <b>self-publisher</b>.&nbsp;</font> </p>
<p><font face="MS Sans Serif" size="2">This eBook will walk you <b>
step by step</b> through writing <b>your</b> <b>first eBook</b> and
then present <b>free</b> resources and <b>marketing plans</b> that
will allow you to market your eBooks using <b>the same</b> free
resources that helped the author publish 3 eBook <b>bestsellers</b>
and two print on demand best selling title </font>
<font face="MS Sans Serif" color="#000000" size="2">at <b>Amazon.com</b></font><font face="MS Sans Serif" size="2">.</font></p>
<p><font face="MS Sans Serif" color="#ff0000" size="2"><u>Full
Resell Rights</u></font><b><font face="MS Sans Serif" size="2">&nbsp;<img src="AB%20NEW/dollars.gif" border="0" width="31" height="16"></font></b>
</td>

This covers one of the images and text within a cell on the page I am trying to upload the gif images from.
These gif's show in 'public.html' - and I can click on each and display them in File manager, but they are not shown when I pull up the page they are supposed to be imported into....
Does that make sense?
At this stage I am tempted to dump the page, but it would be a shame because this is a bit of a bargain offer and would help my site no end...
Over to you, guys...:(

KVN
05-26-2006, 04:33 AM
Hi Nick

When you mention 'public.html' you're referring to an HTML file yeah?

Either way, follow these steps just to make sure we're on the same page

open up the Cpanel File Manager

Click on the public_html directory (make sure it shows '/ public_html / (Current Folder)')

When in this window, you should now see a directory called 'AB NEW' - note all the capitals!
If there isn't a directory, use file manager to create one - and copy your JPG and GIF files into it.
If there is already a directory there (again, making sure the they are all in capitals) make sure the relevant GIFs and JPGs are there.

If all your .html files are in the public_html folder then it should all work.

Let me know how u get on

cheers

KVN

KenJackson
05-26-2006, 05:11 AM
You might want to try using an absolute path. Instead of this:

<img src="AB%20NEW/dollars.gif" ...>
Try this:

<img src="/Webs/AB%20NEW/dollars.gif" ...>
That is, if I understand correctly that you have a "Webs" subdirectory in your public_html directory, and the "AB NEW" subdirectory under that.

nick106b
05-26-2006, 05:24 AM
Thanks guys.
I don't think a new folder in 'public.html' will do it because I had allready used the sub-folder 'images' in there, so I'll try altering the code as JenJackson suggests. Cheers, Nick.

nick106b
05-26-2006, 05:40 AM
Sorry KVN, You are dead RIGHT !!!
Tried Ken's idea and lost the graphic alltogether... Tried KVN's fix - and it works! Promote that person immediately!!!
Now I've just got 100-odd gif's to move to a new folder.
Might be done by the weekend.....zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz
Thanks KVN.

KVN
05-26-2006, 09:31 PM
No worries nick

Just to hit the point home.. there is no specific images directory.
You can place images anywhere you choose, the important thing is that your HTML points to it properly.


Also, I've had a look at your site... remember to include an index.html file on your public_html root directory .... always. Even if it's just a blank file - for security reasons - I should never be able to check your root directory.

cheers

kvn

Early Out
05-26-2006, 09:37 PM
... remember to include an index.html file on your public_html root directory .... always. Even if it's just a blank file - for security reasons - I should never be able to check your root directory.Can't you just use the Index Manager (on the Control Panel) to turn off indexing at that level? That's what I've done. If you try to go to the root of my domain, all you ever see is a "Welcome" page from Bluehost - no hint of what's below it.

Early Out
05-26-2006, 09:50 PM
You have to open up the webpage file, and find out where it thinks the picture files are. Whereever it thinks the .gif files are, that's where they need to be, or it won't be able to find them!Turns out that was, indeed, the solution. Imagine that!

KVN
05-27-2006, 07:06 PM
Easyout

Yup, removing the indexing is an excellent way to protect your site.

my personal preference is to ensure I can move a site between hosts 'at the drop of a hat' - which means I tend not to depend too much on a particular host's server-side configurations for my sites. But that's just my overly cautious nature :rolleyes:


As usual, there are many ways to skin the proverbial cat.
All are good

KVN

Basil
05-28-2006, 12:27 AM
A better solution would have been to go to

ftp://username:password@ftp.yoursite.com
go into the public_html folder and simply drag the entire directory from your machine onto your website.

Since you clearly don't know a thing about web design, I suggest you do a little reading up on it before purchasing a hosting plan.

vegasgwm
05-28-2006, 08:25 PM
See, this is why i say, you want a website, you either pay a webdesigner or LEARN how to do it right.
All this back and forth posting was not even neccesarry. I took one 2 second look at the code, and you can see it.
I don't mean to be rude, but if you missed it, you got a lot to learn my friend instead of acting as if others don't know what their talking about. :rolleyes: Plus... you clearly have no understanding of file names and directory structures.
Building a website is a lot more than putting a pretty picture on a page.
Please learn some html and general computing 101, it will pay off on the long run.:)

illhelpufind
06-01-2006, 07:43 AM
Im Using Page Wizard And Tried To Upload Pictures Using Bmap And Jpeg..it Didnt Take The Bmap But Only Jpeg..can U Tell Me Why???how Can I Upload The Bmap:( ???pls Help Me