Write a script to process all content for insecure content (images, iframes)
- or -
Post a project like this- Posted:
- Proposals: 6
- Remote
- #1376427
- Awarded
Description
Kind of development: Customization of existing website
Description of requirements/features: we need to migrate the entire site to HTTP2 (ssl) this winter. over the last 10 years we have embedded lots of content using http not https (iframes, social media, images, absolute links to other pages in our site using http, etc).
i need a script which runs on node_pre_save() which scans the body text for insecure content and replaces the http with https.
i also need a way to batch run this script for all items of a particular content type.
this should be a separate drupal module with an admin to turn the funcionality on/off and also to batch run on a particular content type.
Extra notes:
James L.
100% (2)New Proposal
Login to your account and send a proposal now to get this project.
Log inClarification Board Ask a Question
-
Are you in a rush or flexible on deadline?
James L.02 Dec 2016flexible. should be ready within 2-3 weeks
-
Hi, Do you want this module in Drupal ? please confirm.
James L.01 Dec 2016yes, it should be a drupal module
-
Maybe there is a simpler solution than doing all that. Please PM me, thank you.
-
hi..I would like to submit a proposal, but there are a few things I need clarified.
1. if i do this module only for hook_node_presave() that will only affect nodes being currently created/edited. That is, it will not affect old nodes. So this module can use hook_nodepresave() but it will also have to scan old nodes of a selected content type.
2. If you change all http to https, especially for external sites, some links may become broken because not all websites use https. Just something to consider.James L.01 Dec 2016hi,
you are correct; node_presave will only work on new/edited nodes. this is why i would like a batch process, using the same code to scan all existing nodes of a particular content type, in order to update their content.
the change to https for links within body text should only be made for external links (not of our domain).
tks
PPH User P.01 Dec 2016ok. so as I understand it, I just have to scan the BODY field for "http" and change it to "https". That's about it.
You want an admin button to turn this entire module on/off...this will only affect node_presave() and not the batch process. That is, you can still manually run a batch process if you wanted too even in off position.
Also you want to run this module on a specific content type that you can choose in admin in a batch process. A batch process may be for 100 nodes for e.g. The next time you run this batch, how will the module know if the node has already been checked? For this check, the module can create a table of its own and note the nids of all nodes already checked.
As I said before, if the module blindly just changes http, to https for external links (and even for social media links), some links may not work because not all external websites use https. I can certainly do this if you want it this way but I cannot be held responsible for broken links...
If you are ok with all of the above, let me know and I will submit a bid. Thanks. -
Hello James,
Was this accidentally posted as an hourly, and is it meant to be fixed price?James L.01 Dec 2016ha! yes you are correct. this was my first post and i made a mistake there! i shall contact pph to change this. 500 is meant to be the maximum budget available; obviously i hope it can be done cheaper. sorry for the confusion
Tope O.01 Dec 2016Hello James,
It can in fact be done a lot cheaper. I think you can edit the job post to reflect your changes.
Best Regards,
Tope Olufon. -
Hello.
What version of Drupal is this and also please make sure the job pricing is accurate: you have a job description for 500 Eur/hour...James L.01 Dec 2016hi, please see my answer above, it was an error on my part! :)
drupal 7
tks