Create a PHP script
- or -
Post a project like this2383
$$$
- Posted:
- Proposals: 6
- Remote
- #1713855
- Completed
Laravel, Vue.js, Python, Machine Learning, Computer Vision, NLP, Shopify, Wordpress, PHP/MySQL, REST APIs, Payment Getewasy(Stripe,Paypal), Bootstrap, Sass, Less, Logo Design
Islamabad
Top rated PHP Web Development | WordPress | Magento | Drupal | OpenCart | PrestaShop | Joomla
Leicester
1583857166809249399105075414546671792110
Description
Experience Level: Expert
Estimated project duration: 1 day or less
General information for the website: Website is an adult themed classifieds website containing adult images
Description of requirements/features: General information for the website: Adult classifieds website with adult images
Kind of development: Customization of existing website
Num. of web pages/modules: 1
Description of requirements/features: We are migrating customers adult themes wordpress site from one theme to a new one. The existing site has around 850 adverts on it, posted by the users of the site.
We are able to migrate the adverts using a plugin, however the images require a more specialised script.
Currently the only information we have in the import file relating to the image is ;
_app_media
a:4:{i:0;i:1877;i:1;i:5712;i:2;i:5713;i:3;i:9460;}
The numbers (1877,5712,5713,9640) relate to post_id of the original uploaded image in MySQL on the old website, which I’ve imported manually into the new MySQL database so that it still has the same ID in the new website. We would need to use your function to query the new MySQL for the _wp_attached_file meta_value (this would return for example “2017/09/548633.jpg”) from which we can assume that the link directly to that image will be http://www.newwebsitedomain.com/wp-content/uploads/2017/09/548633.jpg
You would then need to create a record with meta_key “wpcf-image”, containing the meta_value of
http://www.website.com/wp-content/uploads/2017/09/548633.jpg .
The catch is there could be 4 or 5 of these entries per post.
We have been advised by the company that supplied the import tool:
First, you'd need to write a custom PHP function of your own, that would hook into the "pmxi_saved_post" action (that action would be called as soon as the post is being saved). That function would use the first function ("img_url_by_id") to get the image URL from the ID (once you've unserialized the array).
When it comes to inserting each URL into a field, instead of building a new array, your foreach loop would be inserting each image into a new custom field using the "add_post_meta" function.
Once you've finished this function, you'd insert the code into the Function Editor section in your import template.
Extra notes:
no
Extra notes: General information for the website: Adult classifieds website with adult images
Kind of development: Customization of existing website
Num. of web pages/modules: 1
Description of requirements/features: We are migrating customers adult themes wordpress site from one theme to a new one. The existing site has around 850 adverts on it, posted by the users of the site.
We are able to migrate the adverts using a plugin, however the images require a more specialised script.
Currently the only information we have in the import file relating to the image is ;
_app_media
a:4:{i:0;i:1877;i:1;i:5712;i:2;i:5713;i:3;i:9460;}
The numbers (1877,5712,5713,9640) relate to post_id of the original uploaded image in MySQL on the old website, which I’ve imported manually into the new MySQL database so that it still has the same ID in the new website. We would need to use your function to query the new MySQL for the _wp_attached_file meta_value (this would return for example “2017/09/548633.jpg”) from which we can assume that the link directly to that image will be http://www.newwebsitedomain.com/wp-content/uploads/2017/09/548633.jpg
You would then need to create a record with meta_key “wpcf-image”, containing the meta_value of
http://www.website.com/wp-content/uploads/2017/09/548633.jpg .
The catch is there could be 4 or 5 of these entries per post.
We have been advised by the company that supplied the import tool:
First, you'd need to write a custom PHP function of your own, that would hook into the "pmxi_saved_post" action (that action would be called as soon as the post is being saved). That function would use the first function ("img_url_by_id") to get the image URL from the ID (once you've unserialized the array).
When it comes to inserting each URL into a field, instead of building a new array, your foreach loop would be inserting each image into a new custom field using the "add_post_meta" function.
Once you've finished this function, you'd insert the code into the Function Editor section in your import template.
Extra notes:
Description of requirements/features: General information for the website: Adult classifieds website with adult images
Kind of development: Customization of existing website
Num. of web pages/modules: 1
Description of requirements/features: We are migrating customers adult themes wordpress site from one theme to a new one. The existing site has around 850 adverts on it, posted by the users of the site.
We are able to migrate the adverts using a plugin, however the images require a more specialised script.
Currently the only information we have in the import file relating to the image is ;
_app_media
a:4:{i:0;i:1877;i:1;i:5712;i:2;i:5713;i:3;i:9460;}
The numbers (1877,5712,5713,9640) relate to post_id of the original uploaded image in MySQL on the old website, which I’ve imported manually into the new MySQL database so that it still has the same ID in the new website. We would need to use your function to query the new MySQL for the _wp_attached_file meta_value (this would return for example “2017/09/548633.jpg”) from which we can assume that the link directly to that image will be http://www.newwebsitedomain.com/wp-content/uploads/2017/09/548633.jpg
You would then need to create a record with meta_key “wpcf-image”, containing the meta_value of
http://www.website.com/wp-content/uploads/2017/09/548633.jpg .
The catch is there could be 4 or 5 of these entries per post.
We have been advised by the company that supplied the import tool:
First, you'd need to write a custom PHP function of your own, that would hook into the "pmxi_saved_post" action (that action would be called as soon as the post is being saved). That function would use the first function ("img_url_by_id") to get the image URL from the ID (once you've unserialized the array).
When it comes to inserting each URL into a field, instead of building a new array, your foreach loop would be inserting each image into a new custom field using the "add_post_meta" function.
Once you've finished this function, you'd insert the code into the Function Editor section in your import template.
Extra notes:
no
Extra notes: General information for the website: Adult classifieds website with adult images
Kind of development: Customization of existing website
Num. of web pages/modules: 1
Description of requirements/features: We are migrating customers adult themes wordpress site from one theme to a new one. The existing site has around 850 adverts on it, posted by the users of the site.
We are able to migrate the adverts using a plugin, however the images require a more specialised script.
Currently the only information we have in the import file relating to the image is ;
_app_media
a:4:{i:0;i:1877;i:1;i:5712;i:2;i:5713;i:3;i:9460;}
The numbers (1877,5712,5713,9640) relate to post_id of the original uploaded image in MySQL on the old website, which I’ve imported manually into the new MySQL database so that it still has the same ID in the new website. We would need to use your function to query the new MySQL for the _wp_attached_file meta_value (this would return for example “2017/09/548633.jpg”) from which we can assume that the link directly to that image will be http://www.newwebsitedomain.com/wp-content/uploads/2017/09/548633.jpg
You would then need to create a record with meta_key “wpcf-image”, containing the meta_value of
http://www.website.com/wp-content/uploads/2017/09/548633.jpg .
The catch is there could be 4 or 5 of these entries per post.
We have been advised by the company that supplied the import tool:
First, you'd need to write a custom PHP function of your own, that would hook into the "pmxi_saved_post" action (that action would be called as soon as the post is being saved). That function would use the first function ("img_url_by_id") to get the image URL from the ID (once you've unserialized the array).
When it comes to inserting each URL into a field, instead of building a new array, your foreach loop would be inserting each image into a new custom field using the "add_post_meta" function.
Once you've finished this function, you'd insert the code into the Function Editor section in your import template.
Extra notes:
Mathew S.
100% (9)Projects Completed
12
Freelancers worked with
8
Projects awarded
27%
Last project
8 Apr 2020
United Kingdom
New Proposal
Login to your account and send a proposal now to get this project.
Log inClarification Board Ask a Question
-
There are no clarification messages.
We collect cookies to enable the proper functioning and security of our website, and to enhance your experience. By clicking on 'Accept All Cookies', you consent to the use of these cookies. You can change your 'Cookies Settings' at any time. For more information, please read ourCookie Policy
Cookie Settings
Accept All Cookies