Jump to content

Markus_Newhart

New Members
  • Posts

    4
  • Joined

  • Last visited

Markus_Newhart's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Alright, thanks. Guess ill just reload the page when ever the player posts stuff...
  2. Bump. I still need help.
  3. function showBBcodes($text) { // BBcode array $find = array( '~\[b\](.*?)\[/b\]~s', '~\[i\](.*?)\[/i\]~s', '~\[u\](.*?)\[/u\]~s', '~\[quote\](.*?)\[/quote\]~s', '~\[size=(.*?)\](.*?)\[/size\]~s', '~\[color=(.*?)\](.*?)\[/color\]~s', '~\[url\]((?:ftp|https?)://.*?)\[/url\]~s', '~\[img\](https?://.*?\.(?:jpg|jpeg|gif|png|bmp))\[/img\]~s' ); // HTML tags to replace BBcode $replace = array( '<b>$1</b>', '<i>$1</i>', '<span style="text-decoration:underline;">$1</span>', '<pre>$1</'.'pre>', '<span style="font-size:$1px;">$2</span>', '<span style="color:$1;">$2</span>', '<a href="$1">$1</a>', '<img src="$1" alt="" />' ); // Replacing the BBcodes with corresponding HTML tags return preg_replace($find,$replace,$text); }
  4. I need some help. Im trying to call a php function in ajax. The data variable needs to be inside the called function. Like: _("statusarea").innerHTML = '<div><?php showBBcodes('+data+'); ?></div>'; But no matter what i do it wont call it and if it does call it it wont show the data.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.