News:

SMF 2.1.4 has been released! Take it for a spin! Read more.

Main Menu

Captch not showing and text on top of forum

Started by Martine M, February 02, 2015, 07:03:04 AM

Previous topic - Next topic

Martine M

Link to my forum: http://www.dierenvrienden-tegen-vuurwerk.be/forum/
SMF version: SMF ver. 2.09
Default Forum Language:  Dutch
Theme name and version: Theme name SMF Default Theme - Curve
Browser Name and Version: Browser Firefox 35.0.1 and Opera 12;17
Mods installed: Simple Audio and Video Embedder and TinyPortal
Related Error messages:

Here I am again not all is solved it seems.

In Anti spam I saw that the image of captcha is not showing instead the word 'sample' is visible.
This after clean install yesterday and maybe after installing TinyPortal but I am not sure about that.


This morning I saw this code at the top of the forum it is in the dark blue so it could be I did not notice it before installing TP.
// Let's do something special for session ids! if (defined('SID') && SID != '') $buffer = preg_replace('/"' . preg_quote($scripturl, '/') . '\?(?:' . SID . '(?:;|&|&))((?:board|topic)=[^#"]+?)(#[^"]*?)?"/e', "'\"' . \$scripturl . '/' . strtr('\$1', '&;=', '//,') . '.html?' . SID . '\$2\"'", $buffer); else $buffer = preg_replace('/"' . preg_quote($scripturl, '/') . '\?((?:board|topic)=[^#"]+?)(#[^"]*?)?"/e', "'\"' . \$scripturl . '/' . strtr('\$1', '&;=', '//,') . '.html\$2\"'", $buffer); smflogo.gif


I just saw that if I check "Enable compressed output" in the server settings of smf I only have this on top

smflogo.gif

but I understand that it does not solve the actual problem.
So I hope someone can help me out again.






Running SMF 2.09 - Diego Andrés Theme Elegant Mind - TP 1.0 - Main Forum language English - Browser Firefox 33


Kindred

well, no... your problem, in this case, is not due to file ownership...

if code is showing at the top of the forum - that indicates that a file is not being parsed correctly. Most often, it is one of the language files which has had code added after the ?> (which is supposed to close the file)
In your case, it would seem that same thing happened to one of the other source files...

and settings.php should never, ever, ever show in text - because nothing should EVER edit Settings.php. If it is showing, then something screwed up the actual file... not the chmod or chown.

As for your current display -- it is showing "smflogo" because you have apparently deleted the smf logo image without removing the code that calls for that image (in index.template.php)
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Illori

cant actually read Settings.php from the browser...

QuoteInternal Server Error

File "/home/******/dierenvrienden-tegen-vuurwerk.be/public_html/forum/Settings.php" is writeable by group

Martine M

Sorry deleted my last post about full ownership because I saw before you answered that this was not the problem.

What permission should settings.php be on then 600?

I will check the index.template.php although I had already tired putting originals back but maybe the ?> is missing I'll check it out in the language files.
Running SMF 2.09 - Diego Andrés Theme Elegant Mind - TP 1.0 - Main Forum language English - Browser Firefox 33


Illori


Martine M

It is set to that at the moment Illori also settings.php is now 644
Running SMF 2.09 - Diego Andrés Theme Elegant Mind - TP 1.0 - Main Forum language English - Browser Firefox 33


Illori

are you sure it is showing up that you changed the chmod? if you go to http://www.dierenvrienden-tegen-vuurwerk.be/forum/Settings.php [in chrome] it shows the above error.... it also shows your full path to your files, which IMO it should never do, could be a security risk.

Martine M

I changed it back just now to 600 and it does not show again in the link so I guess it ought to be 600 then.
Running SMF 2.09 - Diego Andrés Theme Elegant Mind - TP 1.0 - Main Forum language English - Browser Firefox 33


Illori

that does fix it, but also removes group from reading it... i guess that may not be an issue on your server. one problem solved... i wonder how many more left.

Martine M

me to Illori, me to. ;)

I just checked all languages files and they are closed and nothing after the close signs.

I will check the other php files out.

Running SMF 2.09 - Diego Andrés Theme Elegant Mind - TP 1.0 - Main Forum language English - Browser Firefox 33


Illori

i dont think it is a closing php tag issue. i think it is bad coding changes. you recent changed your index.template.php file right?

Martine M

I see it has something to do with TIny Portal.
I had to make an edit myself in QueryStrings.php
I have put original back from the text above the forum is gone so maybe I put it in wrong or it does not work right, I'll check it out later.

It did not solve the captcha problem however.
Running SMF 2.09 - Diego Andrés Theme Elegant Mind - TP 1.0 - Main Forum language English - Browser Firefox 33


Martine M

I am going to un-install TP and see what that does.
Running SMF 2.09 - Diego Andrés Theme Elegant Mind - TP 1.0 - Main Forum language English - Browser Firefox 33


Martine M

Tiny Portal problem is solved with the QueryString.php edit, I tried it again and no tekst is showing now above the forum.
So I did not un-install TP


The captcha problem is still there.
I also think the letters of the boards on the index page are bigger then here.
But maybe that doesn't have anything to do with it.
Running SMF 2.09 - Diego Andrés Theme Elegant Mind - TP 1.0 - Main Forum language English - Browser Firefox 33


Martine M

I installed another captcha
http://custom.simplemachines.org/mods/index.php?mod=3824

To see what that would do and it is the same only the text "smple" is showing instead of the image.
Running SMF 2.09 - Diego Andrés Theme Elegant Mind - TP 1.0 - Main Forum language English - Browser Firefox 33


Martine M

Running SMF 2.09 - Diego Andrés Theme Elegant Mind - TP 1.0 - Main Forum language English - Browser Firefox 33


Illori


Martine M

Thanks Illori I'll do this step by step and let you know if I can solve it.
Running SMF 2.09 - Diego Andrés Theme Elegant Mind - TP 1.0 - Main Forum language English - Browser Firefox 33


Martine M

I see several files from TP that not end with ?> all are index.php files that I did not alter????
I will close them and hope it is solved then.
Running SMF 2.09 - Diego Andrés Theme Elegant Mind - TP 1.0 - Main Forum language English - Browser Firefox 33


Martine M

Ok the TP findex files I checked and where closed so I do not understand that.
I did remove space between last entry and de closing but it stays the same.

But QueryString.php was the problem, the checkup set it did not start with <?php
which it does I checked that file before but it was not on the upper line so I fixed that and now Captcha is working.

I am going to try and figure out the TP files still but thanks for all the help. :)
Running SMF 2.09 - Diego Andrés Theme Elegant Mind - TP 1.0 - Main Forum language English - Browser Firefox 33


Kindred

actually, the author of tiny portal might be using the alternate coding method...

see, End Of File (EoF) is sufficient that you don't actually NEED ?>
Now... many of us feel that including the closing tag ?> is actually just clean coding..  but it's not required by php.

However, if there *IS* a closing ?>, then anything added AFTER the ?> (or before the opening <?php) is outside of the code protocols and will cause issues in SMF.
In standard SMF files, <?php should always be the first thing and ?> should always be the last thing in the file
(actually, code before the <?php is often the sign of a hack -- code after the ?> is often the sign of a mod that was mis-installed)
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Martine M

Thanks Kindred for the explanation and help.

The thing is that the tp files are closed and there is nothing before and nothing behind the closing or opening.

All those index files have this code inside and that's all.

<?php

exit;

?>


Still the the file_check says the  ?> is missing.

All seems to work fine now (including TP) so the question is do I have to worry about that?


Running SMF 2.09 - Diego Andrés Theme Elegant Mind - TP 1.0 - Main Forum language English - Browser Firefox 33


Martine M

I also tried to remove the spacings but with the same result.
Running SMF 2.09 - Diego Andrés Theme Elegant Mind - TP 1.0 - Main Forum language English - Browser Firefox 33


Kindred

Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Steve

Quote from: Martine M on February 03, 2015, 07:34:58 AMAll seems to work fine now (including TP) ...

I'm a little confused now. I read back over this thread and are you now saying that all the problems you asked about are resolved?
DO NOT pm me for support!

Martine M

Yes Steve, all problems are solved thanks. :)

Quote from: Kindred on February 03, 2015, 09:23:47 AM
I wouldn't worry about that....

Ok thanks Kindred I won't then. ;)
Running SMF 2.09 - Diego Andrés Theme Elegant Mind - TP 1.0 - Main Forum language English - Browser Firefox 33


Steve

DO NOT pm me for support!

Advertisement: