bhavin12300 Posted July 11, 2007 Share Posted July 11, 2007 hi. here is my problem. as in this site while creating a new topic we are given many feature like insert smliey,code tage bold tag etc. i also wanted to insert this type of tags as i click on particular tag. how to do that? ??? ??? ??? ??? ??? ??? Quote Link to comment Share on other sites More sharing options...
piznac Posted July 11, 2007 Share Posted July 11, 2007 not a clue what you are asking. You might want to try rephrasing that. Quote Link to comment Share on other sites More sharing options...
mosi Posted July 11, 2007 Share Posted July 11, 2007 I'm guessing he means when creating a new post for example on these forums you get the smiley buttons above the textbox to type your post. Then if you click a smiley it inserts code for that in the textbox for you. Not sure of a way to do it exactly becuase I'm tired but I think it's all done with javascript, you could prolly find something from the source of the new post page Just wanted to post to hopefully make your question clearer. Quote Link to comment Share on other sites More sharing options...
AbydosGater Posted July 11, 2007 Share Posted July 11, 2007 Mosi is right. Javascript is used to insert the actual symbols (chars) into the text box. If you look hard enough in the source you will find the code. Then in your php code. When your going to put the post into a database or file just use a str replace... $post = $_POST['message']; $newpost = str_replace("", "<img src=images/smiley_Face.jpg></img>", $post); That will take all the 's in the post and replace them with a link to the image! Andy Quote Link to comment Share on other sites More sharing options...
bhavin12300 Posted July 13, 2007 Author Share Posted July 13, 2007 thasnk you for makking my question clear. and thak you for reply.i did c the code its working perfectly thats you so much. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.