• Resolved shaijuelayidath

    (@shaijuelayidath)


    Hello Friends, I created a custom textfield with WCK which contains the URL path (link to another page). It is working on my localhost. But after i upload my site to production all other links are working except this field. I changed my Site URL and name in database and also run the following query to change localhost links to remote links. ” UPDATE wp_posts SET post_content = REPLACE(post_content, “localhost/x/”, “www.igments.in/x/”); “. Even if WCK field with ‘localhost’ not chaning to remote name.
    Does anyone know whats the reason.
    Thanks in Advance.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author Georgian Cocora

    (@raster02)

    Hello,

    The fields are not stored in the wp_posts table, they are stored in the wp_postmeta table, so they are not changed most likely.

    Run a SELECT * FROM wp_postmeta WHERE 'post_id' = xx to see every field attached to the post with id xx.

    Let me know if you need more help with this.

    Best Regards.

    Thread Starter shaijuelayidath

    (@shaijuelayidath)

    Hi Georgian Cocora, Thanks for your reply

    Actually I am not a programming techie person…iam just a designer only…all the code i taken from tutorial sites and i am not aware about how WCK assigns id for its fields. Following is my URL details:
    localhost: https://localhost/coinoneinvents/
    remote: https://www.coinoneinvents.com/
    So let me know how the query sytax for this which will changes all the WCK textfield links to remote name. Should i run this globally or just standing from ‘wp_postmeta’ table. Thanks for your support.

    Plugin Author Georgian Cocora

    (@raster02)

    Hello,

    Before running this query please make a back-up of your database:
    UPDATE wp_postmeta SET meta_value = REPLACE(meta_value, 'https://localhost/coinoneinvents/', 'https://www.coinoneinvents.com/');

    Let me know if it worked !

    Best Regards.

    Thread Starter shaijuelayidath

    (@shaijuelayidath)

    Hi Georgian Cocora,

    This query works but after running this, HTML part is disappears. I’ll explain you what i did.

    1) Created a ‘WCK Textfield’
    2) Called it in my php page as follows:
    3) In the localhost, my links will be as follows in the WCK CMS fields:
    https://localhost/coinoneinvents/trading-accounting/
    4) When I run the above SQL query, full HTMLs are disappearing in the Frontend.
    5) But in the live site when i am giving the absolute URL as follows, its working fine.
    https://coinoneinvents.com/trading-accounting/
    6) Because of failure of SQL replacing query, now i am copy pasting each and every links in the Live Site.

    Thanks! for the Support

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘custom link issue’ is closed to new replies.