Closed benlk closed 5 years ago
This is probably not going to make it into 0.3 because of time constraints, but there's room for it in a follow-up release.
refactoring in progress, but the network code is not being output! dfpId
is not being set to the value of the network_code
option in window.dfp_options
. In js/jquery.dfw.js
, Object.assign
should be returning the contents of dfw
with the specified items overwriting the values in window.dfw
.
Bumping to 0.4, sorry.
Testing complete locally; lazy-loaded and non- alike render.
Testing complete on a staging site using DFW to serve ads:
This PR is a WIP. 🚨
Changes
Housekeeping:
Implementation of https://github.com/INN/doubleclick-for-wp/issues/63#issuecomment-393342611 to allow filtering of options used by
jquery.dfp.js
:$data
before it's localised by callingapply_filters( 'dfw_js_data', $data )
on itjquery.dfw.js
to load arbitrary options from thedfw
option, same as the footer script.$data
to be the appropriate keys for use as the configuration options thatjQuery.dfp
is looking for. But this might break other uses ofnetwork_code
, and we should keep that in thedfw
JSON object for legacy support.Why
For https://github.com/INN/doubleclick-for-wp/issues/63 and GDPR compliance
Testing/Questions
Questions that need to be answered before merging:
Steps to test this PR: