MyBB Community Forums

Full Version: (Solved) Convert Link to Image
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi, there is, any plugin or metod, to convert a link for example

Mediafire.com/XXX or Megaupload.com/XXX

To a image ? instead see the text link or the text name of the link, automatic put an image.

Thank you Smile

SOLVED:

I use BBCode its not automatic, but you can edit your links, this is the code:

Regular Expression:
\[boton\](.*?)\[/boton\]

And this is the replace:
<A HREF="$1" TARGET="blank"><table height="44" border="0" cellpadding="0" cellspacing="0">
  <tr>
    <td width="178"><img src="http://i.imgur.com/x269C.png" width="178" height="44" /></td>
    <td background="http://i.imgur.com/wElHI.png">$1</td>
    <td width="12%"><img src="http://i.imgur.com/mHOU7.png" width="31" height="44" /></td>
  </tr>
</table></A>

Download the imgur images and put it in your server for security.-
That's all, you can edit the images if you want, and you can put any type of link between this BBCode and will be change it.

[attachment=34425]

http://www.comunidadruso.com.ar
I think u cant find any plugin! Undecided but i have a php code for convert email links to a image. Big Grin
1-make a mail.php page with this codes
<?php
if(!isset($_GET['mail']))
{
die("No mail here");
}
header ("Content-type: image/png");
$textToConvert = $_GET['mail'];
$fontsize = 4;
$width = ImageFontWidth($fontsize) * strlen($textToConvert);
$height = ImageFontHeight($fontsize);
$image = @imagecreate ($width,$height);
$background_color = imagecolorallocate ($image, 255, 255, 255);
$mail_color = imagecolorallocate ($image, 0, 0, 0);
imagestring ($image, $fontsize, 0, 0, $textToConvert, $mail_color);
imagepng ($image);
?>
2-save it in ur root
3-Then wherever you want to take pictures, use the following command
<img src="[email protected]"> 
Note:
[email protected] to put your email address.
Format your page must be php.
That does absolutely no good, mobesta.
Thank you, yes i can try to use that code, with some modifications Smile
Uh... couldn't you just do
<a href="link" title="Link Title"><img src="blah.jpg" alt="Alt Tag" /></a>

...?
Am I the only one who understand what he wants??
but does he want the image linked to the original location of the text, or just to censor/hide the specific content?
Solved.-