How register a custom shortcode for wordpress site?


Hello Friends!

If you want to create a own custom shortcode in your wordpress website, then don’t worry just use my code.

function my_function( $atts ) {
     return "My Name is = {$atts['content']}";
}
add_shortcode('myname', 'my_function');

For register you new shortcode ,just need to add this code in your themes function.php file

Your shortcode [myname content=”raghunath website freelancer”] is ready for use

Note:Change the content in short code during use this shortcode in your website.

Enjoy Raghunath Blog!

Advertisements

Sr. Software Engineer

Tagged with: , , ,
Posted in Wordpress
14 comments on “How register a custom shortcode for wordpress site?
  1. ambien says:

    This post is invaluable. Where can I finhd ouut more?

  2. First off I would like to say fantastic blog! I had a quick question that I’d
    like to ask if you do not mind. I was curious to find out how you center yourself and clear your thoughts prior
    to writing. I have had trouble clearing my mind in getting my ideas out.
    I do enjoy writing but it just seems like the first 10 to
    15 minutes tend to be lost just trying to figure out
    how to begin. Any ideas or hints? Thank you!

  3. Rodrigo says:

    I wanted to thank you for this excellent read!!
    I absolutely loved every bit of it. I’ve got you saved
    as a favorite to check out new things you post…

  4. Laura says:

    After I originally left a comment I seem to have clicked on the
    -Notify me when new comments are added- checkbox and now each
    time a comment is added I recieve 4 emails with the same comment.
    Is there a means you can remove me from that
    service? Thanks!

  5. ideas says:

    I love what you guys are up too. This sort of clever work
    and coverage! Keep up the amazing works guys I’ve incorporated you guys
    to my blogroll.

  6. Barb says:

    Good site you have here.. It’s difficult to find good quality writing like yours these days.

    I honestly appreciate people like you! Take
    care!!

  7. Wonderful post! We are linking to this particularly great post
    on our website. Keep up the great writing.

  8. Theodore says:

    Excellent post. I was checking constantly this blog and I’m
    impressed! Very helpful information particularly the last
    part 🙂 I care for such info much. I was seeking this certain information for a
    very long time. Thank you and good luck.

  9. Timothy Body says:

    Neat Website, Keep up the great job. Thank you!

  10. Vivian says:

    Good post. Idefinitely appreciate this site.

    Continue the good work!

  11. Pretty! This has been an incredibly wonderful post. Thanks for providing this information.

  12. Hi there friends, its fantastic paragraph regarding teachingand fully defined, keep
    it up all the time.

  13. Excellent post. I definitely appreciate this site. Thanks!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: