Imageverification not displayed

Fellyboy 05 Jul, 2007
Hello all

A really great component - gratulations B) But unfortunately I've a little problem with it...

With my local installation (XAMP) - everything is ok. But if I upload the joomla files on my webspace, the image verification is not displayed on the form site. With Firefox V 2.0.0.4, nothing is shown at the place of the verification "field". In the IE 7.0, the white square with the red X is shown.

What's wrong?!

If you want to have a look, please visit my page.

Thanks for all help.

Regards
Markus<br><br>Post edited by: Fellyboy, at: 2007/07/05 19:04
GreyHead 05 Jul, 2007
Hi Fellyboy,

Is the GD extension for PHP installed? Check PHP.info for the install details.

Bob
Fellyboy 05 Jul, 2007
Thanks for your answer, bob!

As I can see in the info.php or in the Joomla Backend: yes.

I just attached a printscreen of the info.php file.

Greetings [file name=GD.zip size=15459]http://www.chronoengine.com/components/com_fireboard/uploaded/files/GD.zip[/file]<br><br>Post edited by: Fellyboy, at: 2007/07/05 19:43
Max_admin 06 Jul, 2007
Hi,

I see the image has errors, this may be unsupported function is used or some problem under this line :

header("Content-type: image/png"«»);


in file : chrono_verification.php

Please try to test and see which line is the problem, because there is no problems at any servers I worked at at all.

Cheers

Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Fellyboy 06 Jul, 2007
Hello

If I type
http://www.nuetzi-schreinerei.ch/joomla/administrator/components/com_chronocontact/chrono_verification.php
in the adressfield of the browser, the following text appears: Die Grafik "http://www.nuetzi-schreinerei.ch/joomla/administrator/components/com_chronocontact/chrono_verification.php" kann nicht angezeigt werden, weil sie Fehler enthält.

Means: the image {imageverification} could not be displayed because the image contains bugs.

On localhost - the image verification is shown correctly.

The line in file chrono_verification.php is exactely the same as you posted, Max.

Thanks!
Markus
Max_admin 06 Jul, 2007
Hi Markus,

What you say is just exactly what I said, so I got a result from this error you see, which is that after this line of code I posted there must be some trouble in the code, I guess one of the functions used isn't defined at your live host and so it makes this error!!

So you can use PHP to check if all functions used are at the PHP version you have on the life server.

Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Fellyboy 06 Jul, 2007
Hello all

Ah sorry - i didn't understand that - I do appologize😉

Ok with which PHP-Code I can check if all the functions needed for ChronoForms are supported on my life-system?!

Or have you a list wiht all needed functions?! So that I can check in the info.php if they are activated.

Is that what I have to do?! Sorry - I'm a Newcomer B)

Thanks for your reply!
Markus
Max_admin 06 Jul, 2007
see here how to check if function exists :

http://www.php.net/function_exists
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Fellyboy 06 Jul, 2007
Ah ok, thanks.

I just changed the CHMOD rights for the components folders on the webserver (now 777). If I want open the chrono_verification.php file on the webserver, the following "message" appears:
<b>Warning</b>:  imagettfbbox(): Could not find/open font in <b>/home/www/web106/html/joomla/administrator/components/com_chronocontact/chrono_verification.php</b> on line <b>21</b><br />


On line 21 I can find: $image_size = imagettfbbox(20, 0, $font, 'X');

Do I have to check this imagettfbbox-function with the script? So I have to create a file named for example function.php with the following content

<?php
if (function_exists('imagettfbbox')) {
    echo "function ok.<br />\n";
} else {
    echo "function not ok.<br />\n";
}
?>


I tested it with the above script - function imagettfbbox is enabled

Thanks!<br><br>Post edited by: Fellyboy, at: 2007/07/06 14:28
Max_admin 06 Jul, 2007
Hi,

No, it cant find teh font file or open it, you should have in the dir with this chrono_verification.php a file called default.ttf, can you find it ? can you extract it from the package and upload ?

Cheers

Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Fellyboy 06 Jul, 2007
Hello

The default.ttf-file is already in the folder.
I atteched a printscreen on which you can see all the files in the chronoform-folder.
The CHMOD rights from webroot to the dir with the chrono_verification.php are all 777.

[file name=chronodir.zip size=41538]http://www.chronoengine.com/components/com_fireboard/uploaded/files/chronodir.zip[/file]
Max_admin 06 Jul, 2007
Hi,

Then try to overwrite it with a fresh one, and assure that you have $font = "default.ttf"; in the chrono_verification.php

Cheers

Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Fellyboy 06 Jul, 2007
Hi,

already done. I overwrote it. The "default.ttf" is in the chrono_verification.php (on line 35).

I use the newest version of chrono form. Downloaded from this page.

Can I change something in the backend?

Regards
Fellyboy 06 Jul, 2007
I just entered the absolute path to the font-file (in different versions)- without any success😟

What about TTF support?! As I can see in the info.php, gd support is enabled.

What about the CHMOD rights? Are there special configurations necessairy?

GD on the server:
GD Support enabled
GD Version 2.0 or higher
FreeType Support enabled
FreeType Linkage with freetype
GIF Read Support enabled
GIF Create Support enabled
JPG Support enabled
PNG Support enabled
WBMP Support enabled

GD localhost:
GD Support enabled
GD Version bundled (2.0.28 compatible)
FreeType Support enabled
FreeType Linkage with freetype
FreeType Version 2.1.9
T1Lib Support enabled
GIF Read Support enabled
GIF Create Support enabled
JPG Support enabled
PNG Support enabled
WBMP Support enabled
XBM Support enabled

Greetings
Markus<br><br>Post edited by: Fellyboy, at: 2007/07/06 19:22
Max_admin 06 Jul, 2007
Hi Markus,

The best way now to test is that you test only the chrono_verification.php with the font file, try getting other font files and try putting the script and the font file in other directories in your server, it should work well anywhere as long as a right path is defined for the font file, I have no idea why this problem occurs for you only but I am sure that with some tests and search you can know where the problem is!

Cheers

Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
r.spilauer 07 Jul, 2007
Hello

I actually had the same problem. After reading this forum and trying a little I have a solution.
Go to Joomla admin section, Global Configuration/Server.
Copy the Absolute Path and insert it to chrono_verification.php in front of the default.ttf. It means twice and it should be lines 20 and 35. Don't forget about "/" between the path and "default.ttf".
Let me know if it works for you too.

Good luck

Radim
bridgecom 07 Jul, 2007
Hi.
I'm having similar problems in getting the image verification to display- any thoughts? I have tried putting an absolute path in front of the default.ttf file as suggested above but no joy.
My site is at http://www.garnffrwdflyfishing.co.uk/joomla and the form is under the enquiries menu tab. Any help would be much appreciated.

Post edited by: bridgecom, at: 2007/07/07 00:08<br><br>Post edited by: bridgecom, at: 2007/07/07 00:14
Max_admin 07 Jul, 2007
Hi,

at chronocontact.php , can we edit the image source at line # 54 to be :
<img src="administrator/components/com_chronocontact/chrono_verification.php">


please let me know the results

Max
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Fellyboy 07 Jul, 2007
Halleluja!

It works!

I deleted all the files on the server - uplaoded all Joomla-files again. And now it seems that this was the solution.

I haven't made the changes in chronocontact.php. Just added the absolute path in chrono_verification.php (on line 20 and 35).

Thanks a lot for all the help!

Nice weekend!
Markus
bridgecom 07 Jul, 2007
Nah. Sorry Max that didn't work:(
Any other thoughts?
bridgecom 07 Jul, 2007
Sorry Max that has not worked. Any other thoughts?
Fellyboy 08 Jul, 2007
Hy all

Have you checked the file and folder permissions?! And the absolute path muss be set on both lines in chrono_verification.php (20 and 35).

What about GD support on your webserver?

Regards
Markus
bridgecom 08 Jul, 2007
I have tried absolute path and the permissions seem to be OK. What is GD support?
GreyHead 09 Jul, 2007
Hi bridgecom,

GD is the PHP graphics extension that's used to create the security images. It's very often installed on server PHP installations - but not always (and not by default).

In Joomla Administrator go to System | System Info and select the PHP Info tab. If you scroll down you will find info on the PHP Extensions. Look for something like the image below.

Bob

Imageverification not displayed image 1
bridgecom 09 Jul, 2007
Thanks Bob.
I had a look and the GD is correctly enabled. However I still don't see the kaptcha image. Wierd.
Chris
GreyHead 09 Jul, 2007
Hi Chris,


It's evening here and I'm just finishing up and off to dinner (been a hard day with the Formula 1 British Grand Prix and the Wimbledon final).

I'll look in the morning and see if I can see a way to create a diagnostic version of the security image creator that will give us a better idea what's happening.

Bob
GreyHead 09 Jul, 2007
Hi Chris,

Some things to try.[list]
  • Check that GD is greater than v 1.6 and has PNG Support enabled (as in the image here)
  • Edit chrono_verification.php to comment out line 17 (see example below) . Paste {mysite}/administrator/components/com_chronocontact/chrono_verification.php in your browser and see what error messages you get. (Replace {mysite} with the url of your site.)
  • [/list]
    Bob
    // header("Content-type: image/png");
    <br><br>Post edited by: GreyHead, at: 2007/07/08 22:34
    frankytsang 09 Jul, 2007
    Hi every1,

    I have got the same prob as well....

    I install the latest version and my server php is GD support.

    I try to change the path but it wont work.

    when I use firebug, i can see the img there (in code) but it just cant find the img, so is not display in the form...

    hope we can slove this prob asap...

    thx
    GreyHead 09 Jul, 2007
    Hi frankytsang,

    When you say that you can 'see the image' in FireBug what's there? Can you post a screen-shot. Might give some clues.

    I'm struggling here and I'm not sure that Max is around at the moment.

    Bob
    frankytsang 09 Jul, 2007
    here it is...

    you can see the code is there under firebug, but somehow it cant display... normally when your mouse on top of the link, it will display the img, but when i roll over, it seems it cant find the img... strange... Imageverification not displayed image 2
    bridgecom 09 Jul, 2007
    Hi Bob,
    Regarding this image verification glitch. I have Community Builder installed and that uses a captcha for registration. This is working fine. Is there maybe some kind of conflict going on with chronoforms?
    What do you think?
    Chris
    GreyHead 09 Jul, 2007
    Hi frankytsang & Chris,

    frankytsang: Thanks for the picture - that's the same as I see in FireBug when the picture works so doesn't take me forward (nice site by the way!)

    Chris: It might be Community Builder but I don't see any good reason for that. There are no functions that might be duplicated . . .

    I'll scratch my head some more.

    Bob

    PS I use SecurityImages and that seems to work fine with ChronoForms.
    Max_admin 10 Jul, 2007
    Hi all,

    Firstly Iam sorry because Iam away nowdays, I see that this is somehow a problem for too many so lets try this :

    in file : chrono_verification.php, there is 2 places where we have $font = "default.ttf", we will do this :

    Change lines like this :
    $font = "default.ttf";

    to be :
    $font = dirname(__FILE__)."/default.ttf";


    Lets try this solution and see if it works, Please any user has the problem report if this solves it or not🙂

    Thanks all!

    Max
    Max, ChronoForms developer
    ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
    ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
    bridgecom 10 Jul, 2007
    Fantastic Max! That did the trick for me:) You're the man! I shall now have to contribute.
    Chris
    frankytsang 10 Jul, 2007
    It still a no good for me...

    I change that 2 lines of code in chrono_verification.php, it happen the same like before, firebug can see the link of the img but seems like it cant display the img...

    :(
    GreyHead 10 Jul, 2007
    Hi Franky,

    Please try this: [ul[[*]Edit chrono_verification.php to comment out line 17 (see example below) . Paste {mysite}/administrator/components/com_chronocontact/chrono_verification.php in your browser and see what error messages you get. (Replace {mysite} with the url of your site e.g. <!-- w --><a class="postlink" href="http://www.kentoni.com.au">www.kentoni.com.au</a><!-- w --> .)[/list]
    Bob
    // header("Content-type: image/png");
    frankytsang 10 Jul, 2007
    Hi Bob,

    I changed the line to

    header("Content-type: http://www.kentoni.com.au/administrator/components/com_chronocontact/chrono_verification.php"«»);


    also try absolute path.

    but nothing happen, just like before.

    :unsure:
    GreyHead 10 Jul, 2007
    Hi Franky,

    I'm not making myself clear.

    1) comment out the line by putting // before it.

    2) go to this url and see if any error messages display.

    3) remove the //

    Bob
    frankytsang 11 Jul, 2007
    Hi Bob,

    I comment out line 17 and it give me this msg

    Fatal error: session_start() [<a href='function.session-start'>function.session-start</a>]: Failed to initialize storage module: user (path: /tmp) in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 6


    I remember something my host told me that about setting absolute path to the temp folder... is that anything to do with it?

    Franky
    GreyHead 11 Jul, 2007
    Hi Franky,

    Most likely yes, I think that the error message says that the system is trying to store the session data in the /tmp folder but the folder either isn't found or isn't writeable.

    Outside my area of competence but I Googled a bit and found a Mambo post that looked as if it might be helpful.

    Bob
    frankytsang 11 Jul, 2007
    Hi Bob,

    Thanks for the google search, I read it and I already went tho that prob when I install Joomla. My ISP change the session.save_handler to file for me and add the absolute path to session.save_path.

    When I open php info, I can see the setting is correct.

    It seems the temp folder is there but somehow it cant find it? scarching head in progress:huh:
    frankytsang 11 Jul, 2007
    I try to add

    ini_set('session.save_handler', 'files');


    before session_start()

    still no image display

    now when I open http://www.kentoni.com.au/administrator/components/com_chronocontact/chrono_verification.php

    it say
    The image “http://www.kentoni.com.au/administrator/components/com_chronocontact/chrono_verification.php” cannot be displayed, because it contains errors.

    when I comment // header("Content-type: image/png");

    it gave me a bunch of error...
    Warning: imagettfbbox() [function.imagettfbbox]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 24
    
    Warning: imagettftext() [function.imagettftext]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 59
    
    Warning: imagettfbbox() [function.imagettfbbox]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 60
    
    Warning: imagettftext() [function.imagettftext]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 59
    
    Warning: imagettfbbox() [function.imagettfbbox]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 60
    
    Warning: imagettftext() [function.imagettftext]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 59
    
    Warning: imagettfbbox() [function.imagettfbbox]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 60
    
    Warning: imagettftext() [function.imagettftext]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 59
    
    Warning: imagettfbbox() [function.imagettfbbox]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 60
    
    Warning: imagettftext() [function.imagettftext]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 59
    
    Warning: imagettfbbox() [function.imagettfbbox]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 60
    
    Warning: imagettftext() [function.imagettftext]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 59
    
    Warning: imagettfbbox() [function.imagettfbbox]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 60
    
    Warning: imagettftext() [function.imagettftext]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 59
    
    Warning: imagettfbbox() [function.imagettfbbox]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 60
    
    Warning: imagettftext() [function.imagettftext]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 75
    
    Warning: imagettfbbox() [function.imagettfbbox]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 76
    
    Warning: imagettftext() [function.imagettftext]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 75
    
    Warning: imagettfbbox() [function.imagettfbbox]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 76
    
    Warning: imagettftext() [function.imagettftext]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 75
    
    Warning: imagettfbbox() [function.imagettfbbox]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 76
    
    Warning: imagettftext() [function.imagettftext]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 75
    
    Warning: imagettfbbox() [function.imagettfbbox]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 76
    
    Warning: imagettftext() [function.imagettftext]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 75
    
    Warning: imagettfbbox() [function.imagettfbbox]: Could not find/open font in /clientdata/clients/k/e/kentoni.com.au/www/administrator/components/com_chronocontact/chrono_verification.php on line 76
    ‰PNG  ��� IHDR���#���(���û|ÔÍ���-IDATX…íÍ1�� µç·…ç�è$ubn“Éd2â„¢L&“Éd2â„¢Lï§"rM 2'����IEND®B`‚


    seems like I over come the session start problem but it cant read the imagettftext function, any idea?

    Franky

    ps... am I heading the right direction?
    Max_admin 12 Jul, 2007
    Hi Franky,

    Regarding the session issue, could you plz comment any line in chrono_verification.php mentions sessions and test again, lets assure that the image gets work first.

    now, please add the fix that worked for other users earlier in the post (bridgecom) and see if the image displays, so now you have fresh file with only sessions lines commented and the hack applied only.

    Max
    Max, ChronoForms developer
    ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
    ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
    GreyHead 12 Jul, 2007
    Hi Franky,

    I've attached a hacked version of admin.chronocontact.html.php Please go to AntiSpam in ChronoForms Admin and set the option to 'No'.

    Then backup your current version and replace it with this one.

    When you look at the anti-spam tab it should show some GD diagnostics and a sample image. (It will also hide the 'Yes' option if GD is not found.)

    Bob

    Imageverification not displayed image 3 [file name=admin.zip size=6190]http://www.chronoengine.com/components/com_fireboard/uploaded/files/admin.zip[/file]<br><br>Post edited by: GreyHead, at: 2007/07/12 11:27
    GreyHead 14 Aug, 2007
    Hi Eelco,

    Thanks, I'll put that into a FAQ here.

    Version 2.3 has some new diagnostics on the Anti Spam tab that can also be helpful before digging deeper with this change.

    Bob
    ifritz 18 Sep, 2008
    Same problem here. Cant see the captch image. What chmod does the chrono_verification.php should have?
    cheers
    GreyHead 18 Sep, 2008
    Hi ifritz,

    Please check FAQ 30 as that may help.

    Bob
    ifritz 18 Sep, 2008
    Thats what i got:

    Warning: require_once() [function.require-once]: SAFE MODE Restriction in effect. The script whose uid is 30 is not allowed to access /home/xxx/html/preview/includes/defines.php owned by uid 2027 in /home/xxx/html/preview/components/com_chronocontact/chrono_verification.php on line 10
    
    Warning: require_once(/home/xxx/html/preview/includes/defines.php) [function.require-once]: failed to open stream: Success in /home/xxx/html/preview/components/com_chronocontact/chrono_verification.php on line 10
    
    Fatal error: require_once() [function.require]: Failed opening required '/home/xxx/html/preview/includes/defines.php' (include_path='.:/usr/lib/php') in /home/xxx/html/preview/components/com_chronocontact/chrono_verification.php on line 10


    Probably a wwwrun problem?
    What do you think?
    Max_admin 19 Sep, 2008
    Hi, which Chronoforms version is this ?
    Max, ChronoForms developer
    ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
    ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
    GreyHead 19 Sep, 2008
    Hi Ifritz,

    This looks like the problem:

    SAFE MODE Restriction in effect. The script whose uid is 30 is not allowed to access . . .


    You, or you isp, will need to add an entry to the safe-mode settings to let user 30 have the extra access.

    Bob
    ifritz 19 Sep, 2008

    Hi, which Chronoforms version is this ?


    Current!
    Max_admin 19 Sep, 2008
    Hi, as Bob said, you will need to check this error with your host, just show them the error and I believe they will have the right solution.

    Regards

    Max
    Max, ChronoForms developer
    ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
    ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
    This topic is locked and no more replies can be posted.

    VPS & Email Hosting 20% discount
    hostinger