Better PHP

Started by homer09001, October 20, 2009, 08:39:32 AM

Previous topic - Next topic

homer09001

SMF Better PHP

Current Version V1.0


SMF Better PHP is a small mod designed for SMF Forums, that improved on the standard formatting of PHP code within PHP BBC tags, the standard formatting applied by SMF 2.0 leaves the php code looking like coloured text with no seperation from the main post.

SMF Better PHP improves this by enclosing the php code in a Quote Style box and making the text bold to stand out better.

Standard PHP Highlighting:
<?//Comment for Hello Worldecho "Hello World"; ?>

With "Better PHP"


Planned Features for V1.1.

  • Select All link
  • Copy to clipboard link

grafitus

Good mod. Congratulations.

ɔɔɔɔɔɔuɥoɾ

hmmm, Nice idea.

but when you use php code in a standard code box you will get the same result

<?phpecho ($some['code'], ' here);?>


SMF 2.0 RC5

   
Webhost to New Webhost file transfer service, PM me - Fast transfers

homer09001

Quote from: ♪ JohnCcCcCc ♫ on October 20, 2009, 11:40:20 AM
hmmm, Nice idea.

but when you use php code in a standard code box you will get the same result

<?phpecho ($some['code'], ' here);?>


yes but that means typing 2 seperate lots of tags, this allows the lot to be done throught 1 set of tags.

ɔɔɔɔɔɔuɥoɾ

I only added code tags ??? to that though

If your talking about <?php and ?>
I suppose this will save a lot of time getting partial PHP code :)


SMF 2.0 RC5

   
Webhost to New Webhost file transfer service, PM me - Fast transfers

homer09001

at the end of they day its down to personal preferance, not everyone knows that Code will highlight PHP plus for Code to highlight php it must containg the open and close tags.

ɔɔɔɔɔɔuɥoɾ

Well nice addition, nice mod

Congratulations on your 1st mod, keep up the modding :D


SMF 2.0 RC5

   
Webhost to New Webhost file transfer service, PM me - Fast transfers

ოկtђ


Hiver101

From what css file can I find the phpcode class?

Darthx

Quote from: Hiver101 on November 04, 2009, 09:10:38 AM
From what css file can I find the phpcode class?

I didnt look at the code but i presume that he is using this php function:
http://www.php.net/manual/en/function.highlight-string.php [nofollow]

Rewards

SAFAD

not updated ?
may i take over this mod .?
Best Regards
Sadaoui "SAFAD" Abderrahim - Lead Developer @ Electron Inc.

homer09001

Feel free, i would update it but i don't have the time.

Advertisement: