• Hello,
    I want to use str_replace only in the AMP version of my site.
    How can I integrate str_replace with this code?
    <?php amp_content(); ?>

    I need to replace (example) “state” to “states”.

    Thank you

Viewing 4 replies - 1 through 4 (of 4 total)
  • Moderator Steven Stern (sterndata)

    (@sterndata)

    Volunteer Forum Moderator

    Whic AMP plugin are you using? I recommend asking at in that plugin’s support area so its developers and support community can help you with this.

    Thread Starter marcorroma

    (@marcorroma)

    I tried with

    <?php amp_content();
    $amp_content = str_replace('state', 'states', $amp_content);?>

    but not work it!

    Thread Starter marcorroma

    (@marcorroma)

    Hi, thanks for your reply.
    Use “AMP for WP”.
    I try to ask them…
    Although I think it is something that does not concern their plugin, but the str_replace function.

    Moderator Steven Stern (sterndata)

    (@sterndata)

    Volunteer Forum Moderator

    The function you’re calling is part of their plugin, so they’re the best folks to ask for docs on using it.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Str_Replace in AMP version’ is closed to new replies.