Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

Ok, bit of a weird one... I want to include php code on one of my pages within the content by adding something like:

Welcome to the payment page
[paymentform]

Blash blah vlha...

And then [paymentform] resolves to a bit of code either somewhere on the filesystem or within the database and handled by a settings page in the backend.

I didn't want to use the exec-php plugin for several reasons - mainly I don't want our client messing with the php code, secondly there are limitations using that with the visual editor etc..etc..

Cheers, John.

share|improve this question
add comment

1 Answer

up vote 1 down vote accepted

Have a look at the Shortcodes API http://codex.wordpress.org/Shortcode_API

share|improve this answer
    
Agreed, shortcodes are the best fit for this. –  supajb May 16 '11 at 0:44
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.