Note that there are some explanatory texts on larger screens.

plurals
  1. POurl cutoff by link module or pagepeeker formatter issue in drupal 7
    primarykey
    data
    text
    <p>I have drupal 7 question that may involve some php help. I have created an rss feed from google alerts that I am mapping into fields. I have had success mapping into all the fields except the link module field where I have put a field formatter that creates a pagepeeker screenshot by attaching the appropriate url server query to the feeds url. Feeds is doing its job by taking the Item URL (link) and putting it into the field correctly. I am having an issue with with either pagepeeker or link module because below keeps happening. </p> <p>To recap- </p> <p>Google Alert feed -> Link module field -> pagepeeker screenshot formatter </p> <p>here's the error </p> <p>The url that google alerts provides is </p> <p><a href="http://www.google.com/url?sa=X&amp;q=http://www.beautyjunkiesunite.com/WP/2012/05/30/whats-new-anastasia-beverly-hills-lash-genius/&amp;ct=ga&amp;cad=CAcQARgAIAEoATAAOABA3t-Y_gRIAlgBYgVlbi1VUw&amp;cd=F7w9TwL-6ao&amp;usg=AFQjCNG2rbJCENvRR2_k6pL9RntjP66Rvg" rel="nofollow">http://www.google.com/url?sa=X&amp;q=http://www.beautyjunkiesunite.com/WP/2012/05/30/whats-new-anastasia-beverly-hills-lash-genius/&amp;ct=ga&amp;cad=CAcQARgAIAEoATAAOABA3t-Y_gRIAlgBYgVlbi1VUw&amp;cd=F7w9TwL-6ao&amp;usg=AFQjCNG2rbJCENvRR2_k6pL9RntjP66Rvg</a></p> <p>When the link is displayed I get :</p> <p><a href="http://pagepeeker.com/thumbs.php?size=m&amp;url=www.google.com/url" rel="nofollow">http://pagepeeker.com/thumbs.php?size=m&amp;url=www.google.com/url</a></p> <p>Its cutting the url at url and not getting the rest of the url. </p> <p>Here's the code that pagepeeker uses to parse the url ?</p> <pre><code>&lt;?php function _pagepeeker_format_url($url, $domain_only = FALSE) { if (filter_var($url, FILTER_VALIDATE_URL) === FALSE) { return FALSE; } // try to parse the url $parsed_url = parse_url($url); if (!empty($parsed_url)) { $host = (!empty($parsed_url['host'])) ? $parsed_url['host'] : ''; $port = (!empty($parsed_url['port'])) ? ':' . $parsed_url['port'] : ''; $path = (!empty($parsed_url['path'])) ? $parsed_url['path'] : ''; $query = (!empty($parsed_url['query'])) ? '?' . $parsed_url['query'] : ''; $fragment = (!empty($parsed_url['fragment'])) ? '#' . $parsed_url['fragment'] : ''; if ($domain_only) { return $host . $port; } else { return $host . $port . $path . $query . $fragment; } } return FALSE; } </code></pre> <p>Could this be the problem?</p> <p>Please let me know I can clarify in any way. </p> <p>What I need is for the entire url to get processed and not just the truncated one </p> <p>Thanks !</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload