Author |
Message |
jjmusicpro
Involved


Joined: Jul 12, 2005
Posts: 283
|
Posted:
Wed Aug 06, 2008 6:46 pm |
|
my site is imagesticky dot com
and im using a prepackaged script that worked fine on my VPS
and now i moved to a Dedicated server
and my site display a bunch of weirld letters and numbers so someone said i sould try putting this in header
header('Content-type: image/jpeg'); //second line
and that worked, made the page show, but why do i have to put that?
is there something in php.ini that i can change? |
_________________ - JJMUSICPRO
Myspacetoolbelt.com || RankBook.com || GamerBomb.com || MyspaceJar.com |
|
|
 |
jestrella
Moderator

Joined: Dec 01, 2005
Posts: 593
Location: Santiago, Dominican Republic
|
Posted:
Wed Aug 06, 2008 8:38 pm |
|
I may be wrong but get nothing when trying to access your site.
using header('Content-type: image/jpeg'); you are telling your browser that content type for the document is a JPEG image, and IMHO it should never be hardcoded in your header file.
all that weird characters may be due to an incompatible charset. |
_________________ "For those whom have not reach the sky... Every mountain seems high"
Best Regards
Jonathan Estrella
http://about.me/jestrella04 |
|
|
 |
jjmusicpro

|
Posted:
Wed Aug 06, 2008 8:46 pm |
|
|
|
 |
jestrella

|
Posted:
Wed Aug 06, 2008 8:54 pm |
|
don't get it...  |
|
|
|
 |
jjmusicpro

|
Posted:
Wed Aug 06, 2008 8:55 pm |
|
i was showing the script i was using, its not something i custom made etc.
i didnt want people saying "check your code"
its simple script, you just upload it, then go to your site and it will walk you through the setup.
however when i uploaded it to my site, i see this
‹¬VëOÜ8ÿ Å4ZØdUmaw«òæD¹Ð£×/+'™M Ž³}HýãolÈ"úîöÃ:Ï{~3öàÕÑŸ‡7¡´•€ñ—ƒ‹óCˆzIr»{˜$G7GðõìæólÇ}¸¶šg6IŽ/#ˆJkë½$™Ïçñ|7VºHn®’~'¹:>ì-œºížÛ÷ß÷·¢¤¥¯%ÎmÖÞì¢Ò _P¹ýáÇ AÎõ0VG ˜,†Ê^‘FNv¯Kp:‘å´Th8=ü§á³at¨¤Ei{7Ë#ÈÂnY\ØÄÙ؇¬dÚ ~¹9é½ ù™–k»ø¢®Ì˜_È^à +º’m8/ŠñŠxR"eº#"Uà·Ü Kc™Ìr%áÊIjÌI8l•JVá0ºÇå\éÜtTy P*c¹,¶`e õŒg¸U#,¯Â3öF ^q‹9¤LæsžÛr Èì~•³^ð$G“i^;—;Î7À$ 3Ëçž(Ñøø¦JÎP/•Ä8¨M™!FÓ yyÎî—q¦ª$ð .ï[^*Vb\)c_6bù½)m– Ük…9gÄ’iDÙÑK¥mÖXà™‹èÉBp#™²™;‰é/ˆ†ð»FîØŒjFg+ÁJ„9&™XRHÆGÔè¬ä2¾3ÑhÉßSl‰bÂe&*DR ¼ Ï•%mG¥*_B&˜¡f) I†BPÇ r>{8ªPÑèµLM½?HèàÙ¹d³I…²qrkƒF¸er8°6a\済벎FgªÂAÂÈbxqªßG–Ù!KUc' yþÉ}Á󛂺¡bG£Ô•5…ë÷KÔf½àá¸IÏà4Ð~,äÐMÖN¹À‰Æš®ü ŸÒÆü4Ü6/s5ÑÔiªZÝ Éû œ;”uå‰ÏïKe¨°JQ›‰)ÞÔÚÊqÑP×L²M{|‹‚à†pêN„M¶¨k«ååyÛ›®Y£•nõ”Ñúú³RWhL8^P”4|ç˜çP2K¤)¢ ¥¡.Ìc tÓÖç:øô ¡/JÔŠNØaŸËÝ7ï\SqðüE|z§JQÌ€c5'tÃ,Ÿ vFã©Z¸.š*ÁU˜õ£?‰ZÀ˜è'Ž°Þ)ÿÊ(¨5Ÿ±l9©‰7£\ÞäÝþ >?ìêvïÇÐaønQ°úª×ƒOyî³| Ô}Åô=4ÖÒvp|z~ ½žoÜŸÎoÇÀrºg¹™4Zý† TÒê|Û'Ò ›8¶\e `{Êþ3¶ºIƒ¶(¤4rŠ<ÏÓ…ð+ÿV..ó.nuû¢Ü™äÁ=èYãs7nït¯œ_¤êøò¨MÔw»Â_çf|t©,œ? uð§ñ7H\øëŒ{´: X}æ%ÜTðÙ=sàŒÞЃCU/µëDØÈ6´ï¶ÜÿûGö-2—Å°áPXµ4é¦óð_ÿÿ ŽPÄ` |
|
|
|
 |
evaders99
Former Moderator in Good Standing

Joined: Apr 30, 2004
Posts: 3221
|
Posted:
Wed Aug 06, 2008 11:08 pm |
|
The script must not be coded correctly. If it is an upload script specifically for JPEG images, then yes.. you will need the header declaration to tell the browser it is image data and not HTML |
_________________ - Only registered users can see links on this board! Get registered or login! -
Need help? Only registered users can see links on this board! Get registered or login! |
|
|
 |
jjmusicpro

|
Posted:
Thu Aug 07, 2008 6:35 am |
|
no the main page has nothing to do with showing an image, its just a normal home page for a site. |
|
|
|
 |
jestrella

|
Posted:
Thu Aug 07, 2008 9:01 am |
|
what kind of file did you upload???
what FTP client did you use???
binary or ASCI mode????
try re-uploading the files with a good FTP client and in the proper transfer mode. |
|
|
|
 |
jjmusicpro

|
Posted:
Thu Aug 07, 2008 9:02 am |
|
i use filezilla
filezilla is set on AUTO type upload
still messed up. |
|
|
|
 |
jestrella

|
Posted:
Thu Aug 07, 2008 9:22 am |
|
have you tried to run the site without the given script????
this way you can determine if is something with the script itself or maybe with the site code. |
|
|
|
 |
jjmusicpro

|
Posted:
Thu Aug 07, 2008 9:24 am |
|
this script runs fine and installs fine on my VPS
but when i try to install this on my dedicated server i get that
i know the script works, but it think its something in my php.ini that needs to be set or turned off. |
|
|
|
 |
Guardian2003
Site Admin

Joined: Aug 28, 2003
Posts: 6799
Location: Ha Noi, Viet Nam
|
Posted:
Thu Aug 07, 2008 12:32 pm |
|
Check what MIMETYPE settings you have between the two different servers. |
|
|
|
 |
jjmusicpro

|
Posted:
Thu Aug 07, 2008 1:39 pm |
|
how and where do i check that? |
|
|
|
 |
Guardian2003

|
Posted:
Fri Aug 08, 2008 4:59 am |
|
You should find it in your servers control panel - Plesk/cPanel vDeck etc
It looks to me like it is trying to execute the content (bytes) of the image rather than treating it as an actual image. The header content trick should work but it is 'better' to make sure the server is handling file types in the correct way. |
|
|
|
 |
|