Html 如何删除rss中的引号
在我的RSS提要中,在drupal视图中有:Html 如何删除rss中的引号,html,drupal,rss,quotes,Html,Drupal,Rss,Quotes,在我的RSS提要中,在drupal视图中有: <link>Prueba "con comillas"</link> 但并非一切都好。我继续看到这一部分: <link>Prueba "con comillas"</link> Prueba“con comillas” 仅用于引用。正如我看到的,您尝试使用视图RSS 有一个修复程序似乎可以工作,但它只在Drupal6站点上测试
<link>Prueba "con comillas"</link>
但并非一切都好。我继续看到这一部分:
<link>Prueba "con comillas"</link>
Prueba“con comillas”
仅用于引用。正如我看到的,您尝试使用视图RSS 有一个修复程序似乎可以工作,但它只在Drupal6站点上测试过。在Drupal 7中,有些内容发生了变化,但请尝试以下内容: 转到视图\u rss/theme并打开theme.inc 复制整个“函数template\u preprocess\u views\u view\u rss”函数,并将其放入主题的template.php中 将函数名更改为:functionyourthemename\u preprocess\u views\u view\u rss 然后在原始主题的第200行,或者在其读取“//将XML元素添加到项数组”的位置,插入以下内容:
if (empty($rss_elements)) continue;
// Insert here -- clean up special characters
$rss_elements[0]['value'] = htmlspecialchars_decode(trim(strip_tags(decode_entities( $rss_elements[0]['value'])),"\n\t\r\v\0\x0B\xC2\xA0 "));
$rss_elements[0]['value'] = htmlspecialchars($rss_elements[0]['value'], ENT_COMPAT);
// end of cleaning
// Add XML element(s) to the item array.
$rss_item['value'] = array_merge($rss_item['value'], $rss_elements);
}
检查你的RSS。。。。您可能需要刷新缓存几次
你可以尝试的另一件事是。在我看来,视图RSS字段的输出可以使用它强制对引号、撇号和符号进行编码
希望能有所帮助。正如我看到的,您尝试使用Views RSS 有一个修复程序似乎可以工作,但它只在Drupal6站点上测试过。在Drupal 7中,有些内容发生了变化,但请尝试以下内容: 转到视图\u rss/theme并打开theme.inc 复制整个“函数template\u preprocess\u views\u view\u rss”函数,并将其放入主题的template.php中 将函数名更改为:functionyourthemename\u preprocess\u views\u view\u rss 然后在原始主题的第200行,或者在其读取“//将XML元素添加到项数组”的位置,插入以下内容:
if (empty($rss_elements)) continue;
// Insert here -- clean up special characters
$rss_elements[0]['value'] = htmlspecialchars_decode(trim(strip_tags(decode_entities( $rss_elements[0]['value'])),"\n\t\r\v\0\x0B\xC2\xA0 "));
$rss_elements[0]['value'] = htmlspecialchars($rss_elements[0]['value'], ENT_COMPAT);
// end of cleaning
// Add XML element(s) to the item array.
$rss_item['value'] = array_merge($rss_item['value'], $rss_elements);
}
检查你的RSS。。。。您可能需要刷新缓存几次
你可以尝试的另一件事是。在我看来,视图RSS字段的输出可以使用它强制对引号、撇号和符号进行编码
希望能有所帮助。正如我看到的,您尝试使用Views RSS 有一个修复程序似乎可以工作,但它只在Drupal6站点上测试过。在Drupal 7中,有些内容发生了变化,但请尝试以下内容: 转到视图\u rss/theme并打开theme.inc 复制整个“函数template\u preprocess\u views\u view\u rss”函数,并将其放入主题的template.php中 将函数名更改为:functionyourthemename\u preprocess\u views\u view\u rss 然后在原始主题的第200行,或者在其读取“//将XML元素添加到项数组”的位置,插入以下内容:
if (empty($rss_elements)) continue;
// Insert here -- clean up special characters
$rss_elements[0]['value'] = htmlspecialchars_decode(trim(strip_tags(decode_entities( $rss_elements[0]['value'])),"\n\t\r\v\0\x0B\xC2\xA0 "));
$rss_elements[0]['value'] = htmlspecialchars($rss_elements[0]['value'], ENT_COMPAT);
// end of cleaning
// Add XML element(s) to the item array.
$rss_item['value'] = array_merge($rss_item['value'], $rss_elements);
}
检查你的RSS。。。。您可能需要刷新缓存几次
你可以尝试的另一件事是。在我看来,视图RSS字段的输出可以使用它强制对引号、撇号和符号进行编码
希望能有所帮助。正如我看到的,您尝试使用Views RSS 有一个修复程序似乎可以工作,但它只在Drupal6站点上测试过。在Drupal 7中,有些内容发生了变化,但请尝试以下内容: 转到视图\u rss/theme并打开theme.inc 复制整个“函数template\u preprocess\u views\u view\u rss”函数,并将其放入主题的template.php中 将函数名更改为:functionyourthemename\u preprocess\u views\u view\u rss 然后在原始主题的第200行,或者在其读取“//将XML元素添加到项数组”的位置,插入以下内容:
if (empty($rss_elements)) continue;
// Insert here -- clean up special characters
$rss_elements[0]['value'] = htmlspecialchars_decode(trim(strip_tags(decode_entities( $rss_elements[0]['value'])),"\n\t\r\v\0\x0B\xC2\xA0 "));
$rss_elements[0]['value'] = htmlspecialchars($rss_elements[0]['value'], ENT_COMPAT);
// end of cleaning
// Add XML element(s) to the item array.
$rss_item['value'] = array_merge($rss_item['value'], $rss_elements);
}
检查你的RSS。。。。您可能需要刷新缓存几次
你可以尝试的另一件事是。在我看来,视图RSS字段的输出可以使用它强制对引号、撇号和符号进行编码
希望能有所帮助。@user3718166:和。Bam@user3718166:和。Bam@user3718166:和。Bam@user3718166:和。砰。