X7ROOT File Manager
Current Path:
/var/softaculous/sitepad/editor/site-data/plugins/siteseo-pro/main
var
/
softaculous
/
sitepad
/
editor
/
site-data
/
plugins
/
siteseo-pro
/
main
/
??
..
??
admin.php
(15.61 KB)
??
ai.php
(9.16 KB)
??
ajax.php
(36.48 KB)
??
alerts.php
(5.76 KB)
??
breadcrumbs.php
(7.68 KB)
??
googleconsole.php
(37.28 KB)
??
googlenews.php
(3.79 KB)
??
gscsetup.php
(13.8 KB)
??
importschema.php
(4.26 KB)
??
install.php
(2.54 KB)
??
linksmanage.php
(3.13 KB)
??
llmtxtfile.php
(2.76 KB)
??
plugin-update-checker.php
(52.57 KB)
??
quickedit.php
(8.66 KB)
??
redirectmanager.php
(10.08 KB)
??
registerblocks.php
(1.57 KB)
??
rsssitemap.php
(6.95 KB)
??
settings
??
structureddata.php
(52.67 KB)
??
tags.php
(14.13 KB)
??
videositemap.php
(13.7 KB)
Editing: linksmanage.php
<?php /* * SITESEO * https://siteseo.io * (c) SiteSEO Team */ namespace SiteSEOPro; if(!defined('ABSPATH')){ die('Hacking Attempt !'); } class LinksManage{ static function init(){ global $siteseo; if(empty($siteseo->pro['toggle_state_external_links'])){ return; } add_filter('the_content', '\SiteSEOPro\LinksManage::manage_external_links', 999); } static function manage_external_links($content){ if(empty($content)){ return $content; } global $siteseo; $options = $siteseo->pro; $nofollow = !empty($options['external_links_nofollow']) ? $options['external_links_nofollow'] : ''; $sponsored = !empty($options['external_links_sponsored']) ? $options['external_links_sponsored'] : ''; $target_blank = !empty($options['external_links_target_blank']) ? $options['external_links_target_blank'] : ''; $noreferrer = !empty($options['external_links_noreferrer']) ? $options['external_links_noreferrer'] : ''; $exclude_links = !empty($options['external_links_exclude']) ? $options['external_links_exclude'] : ''; // Convert exclude domains to array $exclude_domains = array_filter(array_map('trim', explode(',', $exclude_links))); // Get site host $site_host = parse_url(home_url(), PHP_URL_HOST); libxml_use_internal_errors(true); $dom = new \DOMDocument(); $dom->loadHTML('<?xml encoding="utf-8" ?>' . $content); $links = $dom->getElementsByTagName('a'); foreach($links as $link){ $href = $link->getAttribute('href'); if(empty($href)){ continue; } // Skip anchors, mailto, tel if(strpos($href, '#') === 0 || strpos($href, 'mailto:') === 0 || strpos($href, 'tel:') === 0){ continue; } $link_host = parse_url($href, PHP_URL_HOST); // If no host (relative link), skip if(empty($link_host)){ continue; } // Skip internal links if($link_host === $site_host){ continue; } // Check excluded domains $skip = false; foreach($exclude_domains as $domain){ if(strpos($link_host, $domain) !== false){ $skip = true; break; } } if($skip){ continue; } // Get existing rel values $rel = $link->getAttribute('rel'); $rel_values = array_filter(explode(' ', $rel)); // Add rel attributes if(!empty($nofollow) && !in_array('nofollow', $rel_values)){ $rel_values[] = 'nofollow'; } if(!empty($sponsored) && !in_array('sponsored', $rel_values)){ $rel_values[] = 'sponsored'; } if(!empty($noreferrer)){ if(!in_array('noopener', $rel_values)){ $rel_values[] = 'noopener'; } if(!in_array('noreferrer', $rel_values)){ $rel_values[] = 'noreferrer'; } } // Set rel attribute if(!empty($rel_values)){ $link->setAttribute('rel', implode(' ', $rel_values)); } // Target blank if(!empty($target_blank)){ $link->setAttribute('target', '_blank'); } } // Save HTML $html = $dom->saveHTML(); // Remove unwanted tags added by DOMDocument $body = preg_replace('~<(?:!DOCTYPE|/?(?:html|body))[^>]*>\s*~i', '', $html); return $body; } }
Upload File
Create Folder