[SOLVED] Posting HTML code not working

Support for IntegraMOD 141

Moderator: Integra Moderator

[SOLVED] Posting HTML code not working

PostAuthor: .QUACK.Major.Pain » Mon Apr 23, 2007 3:57 pm

Your phpBB Version: 2.0.
phpBB Type: Integramod 141
MODs: No
Your knowledge: Beginner
Board URL: http://www.aaquacks.com/forum

PHP Version:
MySQL Version:


What was done before the problem appeared?



What was done to try to solve the problem?




De.scription and Message

I'm trying to post a google adsense banner in a post using the hmtl code they provide, but doesn't show the banner. It shows some chewed up code.

Code I'm using:

<script><google_ad_client>
</script>
<script>
</script>


My results:

<script><google_ad_client>
</script>
<script>
</script>


I tried "Disable BBCode", using Code and PHP functions above. (didn't think they would work but had to try.
HMTL is set to ON for posting, so should work but not.

Any ideas???
Last edited by .QUACK.Major.Pain on Sun Jul 22, 2007 1:52 pm, edited 1 time in total.

.QUACK.Major.Pain
Sr Integra Member
Sr Integra Member
 
Posts: 986
Likes: 0 post
Liked in: 0 post
Joined: Sat Jan 27, 2007 11:15 am
Cash on hand: 0.00

Re: Posting HTML code not working

PostAuthor: Helter » Mon Apr 23, 2007 5:24 pm

in acp/general admin/Configuration
choose "allow html"

It is a security risk though to allow html in posts
Last edited by Helter on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.
"Success is getting what you want. Happiness is wanting what you get." - Dale Carnegie
User avatar
Helter
Administrator
Administrator
 
Posts: 4554
Likes: 40 posts
Liked in: 116 posts
Images: 0
Joined: Sat Mar 11, 2006 4:46 pm
Cash on hand: 1,959.15
Location: Seattle Wa
IntegraMOD version: phpBB2x

Re: Posting HTML code not working

PostAuthor: .QUACK.Major.Pain » Mon Apr 23, 2007 5:51 pm

As I said above it is already turned on.
It shows under post screen

HTML is ON

Not working.
Last edited by .QUACK.Major.Pain on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.

.QUACK.Major.Pain
Sr Integra Member
Sr Integra Member
 
Posts: 986
Likes: 0 post
Liked in: 0 post
Joined: Sat Jan 27, 2007 11:15 am
Cash on hand: 0.00

PostAuthor: Whisky » Tue Apr 24, 2007 12:38 am

same on my board, HTML code in posts is not working and the HTML is ON

that's not a big deal but I would like to understand why
Last edited by Whisky on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.
I am the Lizard King, I can do anything

Whisky
Sr Integra Member
Sr Integra Member
 
Posts: 256
Likes: 0 post
Liked in: 0 post
Joined: Thu May 18, 2006 2:28 am
Cash on hand: 0.00
Location: Brussels

Re: Posting HTML code not working

PostAuthor: Frost » Tue Apr 24, 2007 2:29 am

I can offer a temporary solution for adding your adsense until Helter looks this over for you because as he said it is a major security risk enabling HTML code in your posts. (Look at myspace.. sorry cheap shot <img> )

Anyways, I can show you how to alter your code to make the adsense appear on the post's page somewhere on every page of posts if you'd like.

For example, show ads as second post, show ads above every first post, or after every last post etc...

For the actual problem, I think it's either an error in code in posting.php or you're trying to use this html in your signature

let's see if it's getting set

Open posting.php

Find,
Code: Select all
    $html_on = 0;


If it doesn't exist then you do indeed have it enabled

To double check

Find,
Code: Select all
    $html_on = 1;
Last edited by Frost on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.
[size=99px]PhpBB3 Themes[/url] ]PhpBB3 Development Center[/url] [/size]

Frost
Sr Integra Member
Sr Integra Member
 
Posts: 776
Likes: 0 post
Liked in: 0 post
Joined: Wed Sep 13, 2006 2:04 am
Cash on hand: 0.00
Location: Photoshop CS3

Re: Posting HTML code not working

PostAuthor: .QUACK.Major.Pain » Tue Apr 24, 2007 4:46 am

Found it and it was 0 - changed it to 1 and same result - still not working

Also there are extra spaces after ?> - removed them but still not working.
Last edited by .QUACK.Major.Pain on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.

.QUACK.Major.Pain
Sr Integra Member
Sr Integra Member
 
Posts: 986
Likes: 0 post
Liked in: 0 post
Joined: Sat Jan 27, 2007 11:15 am
Cash on hand: 0.00

Re: Posting HTML code not working

PostAuthor: Frost » Thu Apr 26, 2007 6:04 am

Hmm, did you try adding the code you were going to use?

See Demo: [url=http]HERE[/url]
Last edited by Frost on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.
[size=99px]PhpBB3 Themes[/url] ]PhpBB3 Development Center[/url] [/size]

Frost
Sr Integra Member
Sr Integra Member
 
Posts: 776
Likes: 0 post
Liked in: 0 post
Joined: Wed Sep 13, 2006 2:04 am
Cash on hand: 0.00
Location: Photoshop CS3

PostAuthor: shedt_v » Thu Apr 26, 2007 6:38 am

Will this work with the KB? I want to use html in a KB article.
Last edited by shedt_v on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.

shedt_v
Integra Member
Integra Member
 
Posts: 114
Likes: 0 post
Liked in: 0 post
Joined: Sat Dec 09, 2006 8:37 am
Cash on hand: 0.00

Re: Posting HTML code not working

PostAuthor: Frost » Thu Apr 26, 2007 6:42 am

I'm not sure, it should, but you might want to wait for HelterSkelter's reply because I don't ever use the KB
Last edited by Frost on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.
[size=99px]PhpBB3 Themes[/url] ]PhpBB3 Development Center[/url] [/size]

Frost
Sr Integra Member
Sr Integra Member
 
Posts: 776
Likes: 0 post
Liked in: 0 post
Joined: Wed Sep 13, 2006 2:04 am
Cash on hand: 0.00
Location: Photoshop CS3

PostAuthor: shedt_v » Thu Apr 26, 2007 3:51 pm

I think I was just putting in the wrong tags. I was not using the <

My questions is, for the KB config, how can I make the allowed tags text input box where i type in, bigger? Or what file would I need to edit?

I guess I'll take a peek in the admin tpl files.
Last edited by shedt_v on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.

shedt_v
Integra Member
Integra Member
 
Posts: 114
Likes: 0 post
Liked in: 0 post
Joined: Sat Dec 09, 2006 8:37 am
Cash on hand: 0.00

PostAuthor: shedt_v » Thu Apr 26, 2007 6:16 pm

ok, I pretty much have done what I needed, but I can't get this code to display correctly in a KB article.

If anyone knows how I can add it to anything else (block, forum post) anything, please let me know.

[code]<frameset>    <frame name="menu" src="http]

The first src as you can see is a KB article with only the links. It works prefect, but I want to get rid of the html file (i'm going to need to create more i think anyways)

If not it's not big deal, but it would be awesome if someone could give me a tip.

take care.
Last edited by shedt_v on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.

shedt_v
Integra Member
Integra Member
 
Posts: 114
Likes: 0 post
Liked in: 0 post
Joined: Sat Dec 09, 2006 8:37 am
Cash on hand: 0.00

Re: Posting HTML code not working

PostAuthor: .QUACK.Major.Pain » Fri Apr 27, 2007 1:46 pm

Frost I tried doing that demo you posted and when I click submit I got the following error:

Forbidden
You don't have permission to access /forum/admin/admin_board.php on this server.

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.


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

Apache/1.3.34 Server at http://www.aaquacks.com Port 80


Is that a problem with the host?
Last edited by .QUACK.Major.Pain on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.

.QUACK.Major.Pain
Sr Integra Member
Sr Integra Member
 
Posts: 986
Likes: 0 post
Liked in: 0 post
Joined: Sat Jan 27, 2007 11:15 am
Cash on hand: 0.00

Re: Posting HTML code not working

PostAuthor: Frost » Fri Apr 27, 2007 8:25 pm

Hmm check the permissions, it should be 644

If it is, make sure your cookie settings are right, that you are logged in as board founder, and as a last resort, delete cookies, and re-login
Last edited by Frost on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.
[size=99px]PhpBB3 Themes[/url] ]PhpBB3 Development Center[/url] [/size]

Frost
Sr Integra Member
Sr Integra Member
 
Posts: 776
Likes: 0 post
Liked in: 0 post
Joined: Wed Sep 13, 2006 2:04 am
Cash on hand: 0.00
Location: Photoshop CS3

Re: Posting HTML code not working

PostAuthor: .QUACK.Major.Pain » Sat Apr 28, 2007 1:00 pm

It is chmod 644, deleted cookies and re-logged in.
Tried again with the same error.

I then tried adding just ,<script> without the </script> and
I then got a CT error.
Debug info:

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Script-Filename: /forum/admin/admin_board.php ---------------- Request-Method: POST Matching rule: <.script In variable: allow_html_tags Possible solution: ------------------ # #-----[ OPEN ]------------------------------------------ # /forum/admin/admin_board.php # #-----[ FIND ]------------------------------------------ # define('IN_PHPBB', 1); # #-----[ AFTER, ADD ]------------------------------------------ # define('CT_SECLEVEL', 'MEDIUM'); $ct_ignorepvar = array('allow_html_tags'); # #-----[ SAVE/CLOSE ALL FILES ]------------------------------------------ # # EoM


Sry quote messed up - logmanager posted it weird.
Did the suggested debug and no more error

Tried adding both again but post still messed up.
Tried adding .script and tried adding .script,/.script without <>, still messed up.

No fix yet.
Last edited by .QUACK.Major.Pain on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.

.QUACK.Major.Pain
Sr Integra Member
Sr Integra Member
 
Posts: 986
Likes: 0 post
Liked in: 0 post
Joined: Sat Jan 27, 2007 11:15 am
Cash on hand: 0.00

Re: Posting HTML code not working

PostAuthor: Frost » Sun Apr 29, 2007 1:02 pm

Hmm, I'll try adding it to my board, and go through everything I can think of, then I'll post back if I get it to work
Last edited by Frost on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.
[size=99px]PhpBB3 Themes[/url] ]PhpBB3 Development Center[/url] [/size]

Frost
Sr Integra Member
Sr Integra Member
 
Posts: 776
Likes: 0 post
Liked in: 0 post
Joined: Wed Sep 13, 2006 2:04 am
Cash on hand: 0.00
Location: Photoshop CS3

Re: Posting HTML code not working

PostAuthor: tekguru » Sun Apr 29, 2007 10:53 pm

"Frost";p="24359" wrote:Anyways, I can show you how to alter your code to make the adsense appear on the post's page somewhere on every page of posts if you'd like.

For example, show ads as second post, show ads above every first post, or after every last post etc...


Frost I'd be very interested in the above.....
Last edited by tekguru on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.
[size=99px]http][/size]
[url=http][img=left]http://www.4winmobile.com/news/MVP_Horizontal_FullColor.png[/img][/url]
User avatar
tekguru
Sr Integra Member
Sr Integra Member
 
Posts: 329
Likes: 0 post
Liked in: 0 post
Joined: Tue Mar 28, 2006 11:29 pm
Cash on hand: 0.00

Re: Posting HTML code not working

PostAuthor: Frost » Mon Apr 30, 2007 4:42 pm

Ok, show me the code they gave you and I'll show you how to add it

Also, where do you want the ad to appear?
Last edited by Frost on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.
[size=99px]PhpBB3 Themes[/url] ]PhpBB3 Development Center[/url] [/size]

Frost
Sr Integra Member
Sr Integra Member
 
Posts: 776
Likes: 0 post
Liked in: 0 post
Joined: Wed Sep 13, 2006 2:04 am
Cash on hand: 0.00
Location: Photoshop CS3

Re: Posting HTML code not working

PostAuthor: .QUACK.Major.Pain » Mon Apr 30, 2007 4:47 pm

My code is at beginning of this thread.
I wanted to put it in a post and react the same as if it was in a banner.
Last edited by .QUACK.Major.Pain on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.

.QUACK.Major.Pain
Sr Integra Member
Sr Integra Member
 
Posts: 986
Likes: 0 post
Liked in: 0 post
Joined: Sat Jan 27, 2007 11:15 am
Cash on hand: 0.00

Re: Posting HTML code not working

PostAuthor: Frost » Mon Apr 30, 2007 5:19 pm

I was talking to tekguru there, but in reply to you, I have tried to add the code myself to my forum and get the same result.

I am currently digging through files and looking for the preg_replace but I'm having no luck as of yet.

Either way, I think it is a very bad idea to allow anyone but yourself to use html in their posts. I don't think you grasp what people can do with html. I could take down your entire site if I could use html...

Anyway, after you posted last, all you're wanting to do is have the ads appear in the post?

I thought for some reason you wanted to manually ad the code in a post. There is no need for this as there are plenty of mods, and different ways, to do this without allowing html on your board.

I will post a follow up with some mods that do what (I think you ALL are looking for).
Last edited by Frost on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.
[size=99px]PhpBB3 Themes[/url] ]PhpBB3 Development Center[/url] [/size]

Frost
Sr Integra Member
Sr Integra Member
 
Posts: 776
Likes: 0 post
Liked in: 0 post
Joined: Wed Sep 13, 2006 2:04 am
Cash on hand: 0.00
Location: Photoshop CS3

Re: Posting HTML code not working

PostAuthor: .QUACK.Major.Pain » Mon Apr 30, 2007 5:45 pm

No problem. I was just looking to get the banner that the above code would produce in a post.

We are putting an area in our forum for information on how to make money on the side by advertising.

I have added other sites, but the above code uses html and I don't know enough to convert it.

Also wanted it to work so that we get the credit for the referal if someone chooses to join by clicking our banner.

Thx ahead of time!!!
Last edited by .QUACK.Major.Pain on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.

.QUACK.Major.Pain
Sr Integra Member
Sr Integra Member
 
Posts: 986
Likes: 0 post
Liked in: 0 post
Joined: Sat Jan 27, 2007 11:15 am
Cash on hand: 0.00

Re: Posting HTML code not working

PostAuthor: Frost » Mon Apr 30, 2007 6:04 pm

To add your google adsense between the 1st and 2nd posts

STOP! - Backup your files first!

Open viewtopic.php

Find
Code: Select all
include($phpbb_root_path . 'common.'.$phpEx);


After, Add
Code: Select all
 $adblocktext = <<<EOM<tr><td>Insert your Google AdSense Code Here</td></tr>  <tr><td><imgsrc></td></tr>EOM;  


Find
Code: Select all
for($i = 0; $i <total_posts> $l_edited_by,


After, Add
Code: Select all
        'AD_BLOCK' => $adblock,


Open viewtopic_body.tpl


Find (Second instance, around line 200)
Code: Select all
<END>


Before, Add
Code: Select all
{postrow.AD_BLOCK}


Save, Close all files

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

Now, you need to edit a few parts of these instructions.

You need to replace "Insert your Google AdSense Code Here" with your ad code. For this test I used the code that .=QUACK=.Major.Pain supplied in an earlier post.

You also need to replace "templates/yourtheme/images/spacer.gif" with whatever theme you are using. Or at least any theme that you know you will keep. (spacer is transparent)

You can edit or play around with this to achieve the best results for you.

Have fun <img>
Last edited by Frost on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.
[size=99px]PhpBB3 Themes[/url] ]PhpBB3 Development Center[/url] [/size]

Frost
Sr Integra Member
Sr Integra Member
 
Posts: 776
Likes: 0 post
Liked in: 0 post
Joined: Wed Sep 13, 2006 2:04 am
Cash on hand: 0.00
Location: Photoshop CS3

Re: Posting HTML code not working

PostAuthor: .QUACK.Major.Pain » Mon Apr 30, 2007 6:24 pm

That would put between 1st and 2nd of all posts in all topics?
Last edited by .QUACK.Major.Pain on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.

.QUACK.Major.Pain
Sr Integra Member
Sr Integra Member
 
Posts: 986
Likes: 0 post
Liked in: 0 post
Joined: Sat Jan 27, 2007 11:15 am
Cash on hand: 0.00

Re: Posting HTML code not working

PostAuthor: Frost » Tue May 01, 2007 3:46 am

yes
Last edited by Frost on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.
[size=99px]PhpBB3 Themes[/url] ]PhpBB3 Development Center[/url] [/size]

Frost
Sr Integra Member
Sr Integra Member
 
Posts: 776
Likes: 0 post
Liked in: 0 post
Joined: Wed Sep 13, 2006 2:04 am
Cash on hand: 0.00
Location: Photoshop CS3

Re: Posting HTML code not working

PostAuthor: .QUACK.Major.Pain » Tue May 01, 2007 4:40 am

Ok thx - not what I was looking for.
Already have adsense in my banners, so would just be duplicating.

Was looking to use in a single post as a how to guide for making money with adsense.
Last edited by .QUACK.Major.Pain on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.

.QUACK.Major.Pain
Sr Integra Member
Sr Integra Member
 
Posts: 986
Likes: 0 post
Liked in: 0 post
Joined: Sat Jan 27, 2007 11:15 am
Cash on hand: 0.00

Re: Posting HTML code not working

PostAuthor: Frost » Tue May 01, 2007 5:55 am

You would have to figure out why you cannot use java.script/html in your posts. I've looked but I don't know why it is like that. Obviously something somewhere is replacing instances of <script> with <script>, may be java.script blocking, not html.

Why don't you just make a small html page with the code inside, then use IntegraMOD's "Insert Web Page" to show it in a post?
Last edited by Frost on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.
[size=99px]PhpBB3 Themes[/url] ]PhpBB3 Development Center[/url] [/size]

Frost
Sr Integra Member
Sr Integra Member
 
Posts: 776
Likes: 0 post
Liked in: 0 post
Joined: Wed Sep 13, 2006 2:04 am
Cash on hand: 0.00
Location: Photoshop CS3

Re: Posting HTML code not working

PostAuthor: .QUACK.Major.Pain » Tue May 01, 2007 11:47 am

Ok - see what I can dream up. LOL
Sounds possible.
Last edited by .QUACK.Major.Pain on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.

.QUACK.Major.Pain
Sr Integra Member
Sr Integra Member
 
Posts: 986
Likes: 0 post
Liked in: 0 post
Joined: Sat Jan 27, 2007 11:15 am
Cash on hand: 0.00

Re: Posting HTML code not working

PostAuthor: .QUACK.Major.Pain » Tue May 01, 2007 1:10 pm

ok I took an attempt at it.

I tried this:

<html>
<script><google_ad_client>
</script>
<script>
</script>
</html>


I first tried the code as is and didn't work.
I added the <html> and </html> and didn't work

you can see my results here: http://www.aaquacks.com/forum/adsense.html

I need a little help with the proper coding cause I suck LOL.
Last edited by .QUACK.Major.Pain on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.

.QUACK.Major.Pain
Sr Integra Member
Sr Integra Member
 
Posts: 986
Likes: 0 post
Liked in: 0 post
Joined: Sat Jan 27, 2007 11:15 am
Cash on hand: 0.00

Re: Posting HTML code not working

PostAuthor: .QUACK.Major.Pain » Wed May 02, 2007 1:32 pm

I hope someone can get the html working in posts.
We also use a Buy/Sell/Trade section and want to use "Buy Now" paypal button, and it's also in html.

If html is such a security risk, why is it that paypal, adsense, youtube, metcalfe, and others only provide html coding?
Last edited by .QUACK.Major.Pain on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.

.QUACK.Major.Pain
Sr Integra Member
Sr Integra Member
 
Posts: 986
Likes: 0 post
Liked in: 0 post
Joined: Sat Jan 27, 2007 11:15 am
Cash on hand: 0.00

Re: Posting HTML code not working

PostAuthor: .QUACK.Major.Pain » Wed May 09, 2007 8:13 pm

No ideas for a fix yet?
Last edited by .QUACK.Major.Pain on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.

.QUACK.Major.Pain
Sr Integra Member
Sr Integra Member
 
Posts: 986
Likes: 0 post
Liked in: 0 post
Joined: Sat Jan 27, 2007 11:15 am
Cash on hand: 0.00

Re: Posting HTML code not working

PostAuthor: Helter » Sun Jul 22, 2007 12:26 pm

you must add any html tags you want to use in the "Allowed HTML tags" section of Genral Admin/Configuration

add "table,object,tr,td," to "Allowed HTML tags"

in your forum root, make a folder called html.
you need to add 2 files to it.
first make an empty file named index.html - this will keep users from browsing the contents of the folder.
next make a file called "google.html" add the text below to this file

[web height=350:5vlnugdq]http://www.integramod.com/html/google.txt[/web:5vlnugdq]

add the text below to your post or sig

[code]  <table>   <tr>     <td>       <OBJECT data="http]

this is the output

<table>
<tr>
<td>
<OBJECT>
Warning: google.html could not be embedded.
</OBJECT>
</td>
</tr>
</table>
Last edited by Helter on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.
"Success is getting what you want. Happiness is wanting what you get." - Dale Carnegie
User avatar
Helter
Administrator
Administrator
 
Posts: 4554
Likes: 40 posts
Liked in: 116 posts
Images: 0
Joined: Sat Mar 11, 2006 4:46 pm
Cash on hand: 1,959.15
Location: Seattle Wa
IntegraMOD version: phpBB2x

Re: Posting HTML code not working

PostAuthor: .QUACK.Major.Pain » Sun Jul 22, 2007 1:52 pm

Ok thx Helter. We were having problem with the .script code before.

I actually figured out the problem by looking at your last reply.

I was putting in ACP>General Admin>Configuration

Allowed html: .script, td, tr, etc.

When doing it, I was putting in spaces after the , which frigs it all up.
If it's done without, .script,td,tr,etc everything works fine.

I've tried it and have got both google ads and pay now button to work great.

Thanks again Helter.
Last edited by .QUACK.Major.Pain on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.

.QUACK.Major.Pain
Sr Integra Member
Sr Integra Member
 
Posts: 986
Likes: 0 post
Liked in: 0 post
Joined: Sat Jan 27, 2007 11:15 am
Cash on hand: 0.00

Re: Posting HTML code not working

PostAuthor: .QUACK.Major.Pain » Sun Jul 22, 2007 2:01 pm

solved
Last edited by .QUACK.Major.Pain on Wed Dec 31, 1969 5:00 pm, edited 1 time in total.

.QUACK.Major.Pain
Sr Integra Member
Sr Integra Member
 
Posts: 986
Likes: 0 post
Liked in: 0 post
Joined: Sat Jan 27, 2007 11:15 am
Cash on hand: 0.00


Return to IntegraMOD 141

Who is online

Registered users: App360MonitorBot, Bing [Bot], Google [Bot], Majestic-12 [Bot]