![]() |
![]() |
![]()
Post
#1
|
|
Grupa: Zarejestrowani Postów: 5 Pomógł: 0 Dołączył: 2.02.2016 Ostrzeżenie: (0%) ![]() ![]() |
Witam,
na mojej stronie pojawił się taki błąd : Parse error: syntax error, unexpected T_STRING in /(...)/ski.wp.customizer.php on line 41 Line 41 zaczyna się tu : trait cz_supplement Przeszukam kilka razy ten kod w celu znalezienia tego błędu ale bez skutecznie. jest szansa aby ktoś mi pomógł? Będę wdzięczna za wszelką pomoc. Pozdrawiam, CODE add_action( 'customize_controls_enqueue_scripts', 'ski\cz_enqueue' ); /** * Defining a trait here means that we can continue to derive from the existing * WP controls, but add in our additional attributes without changing the signature. * * @author Dan Suleski * @since 2.0 */ trait cz_supplement { /** * @var string Optional description to be displayed near the option title */ public $desc = ''; /** * @var string Optional description to be displayed after the main control */ public $desc_after = ''; /** * The label should be uniform for every control - so just lay it out * once and reference it from the render_content callback everywhere. */ public function get_label_markup() { if ( empty( $this->label ) ) return ''; return '<p class="customize-control-title">'.$this->label.'</p>'; } /** * The description should be uniform for every control - so just lay it out * once and reference it from the render_content callback everywhere. */ public function get_description_markup() { if ( empty( $this->desc ) ) return ''; return '<p class="cc-description">'.$this->desc.'</p>'; } /** * Just like the description that comes first, the description that comes after * the main control should be uniform for each of these controls - so just lay * it out once and reference it from the render_content callback everywhere. */ public function get_description_after_markup() { if ( empty( $this->desc_after ) ) return ''; return '<p class="cc-description-after">'.$this->desc_after.'</p>'; } /** * The label and description should be uniform for every control - so just lay it out * once and reference it from the render_content callback everywhere. */ public function get_label_description_markup() { return $this->get_label_markup(); $this->get_description_markup(); } |
|
|
![]() |
![]()
Post
#2
|
|
Grupa: Zarejestrowani Postów: 6 380 Pomógł: 1116 Dołączył: 30.08.2006 Ostrzeżenie: (0%) ![]() ![]() |
Jaka wersja PHP?
-------------------- |
|
|
![]()
Post
#3
|
|
![]() Grupa: Moderatorzy Postów: 36 557 Pomógł: 6315 Dołączył: 27.12.2004 ![]() |
trait wymaga PHP 5.4.0 lub nowszego
-------------------- "Myśl, myśl, myśl..." - Kubuś Puchatek || "Manual, manual, manual..." - Kubuś Programista "Szukaj, szukaj, szukaj..." - Kubuś Odkrywca || "Debuguj, debuguj, debuguj..." - Kubuś Developer |
|
|
![]()
Post
#4
|
|
Grupa: Zarejestrowani Postów: 5 Pomógł: 0 Dołączył: 2.02.2016 Ostrzeżenie: (0%) ![]() ![]() |
Przepraszam za głupie pytanie ale gdzie mogę znaleźć wersje php?
chyba mam 5.2.2 Ten post edytował pokemon1980 2.02.2016, 17:33:32 |
|
|
![]()
Post
#5
|
|
Grupa: Zarejestrowani Postów: 6 380 Pomógł: 1116 Dołączył: 30.08.2006 Ostrzeżenie: (0%) ![]() ![]() |
-------------------- |
|
|
![]()
Post
#6
|
|
Grupa: Zarejestrowani Postów: 5 Pomógł: 0 Dołączył: 2.02.2016 Ostrzeżenie: (0%) ![]() ![]() |
w pliku xmlrpc.php znalazłam taką informacje :
CODE <?php /** * XML-RPC protocol support for WordPress * * @package WordPress */ /** * Whether this is an XML-RPC Request * * @var bool */ define('XMLRPC_REQUEST', true); // Some browser-embedded clients send cookies. We don't want them. $_COOKIE = array(); // A bug in PHP < 5.2.2 makes $HTTP_RAW_POST_DATA not set by default, // but we can do it ourself. if ( !isset( $HTTP_RAW_POST_DATA ) ) { $HTTP_RAW_POST_DATA = file_get_contents( 'php://input' ); } // fix for mozBlog and other cases where '<?xml' isn't on the very first line if ( isset($HTTP_RAW_POST_DATA) ) $HTTP_RAW_POST_DATA = trim($HTTP_RAW_POST_DATA); więc chyba mam wersje 5.2.2 |
|
|
![]()
Post
#7
|
|
![]() Grupa: Zarejestrowani Postów: 8 068 Pomógł: 1414 Dołączył: 26.10.2005 Ostrzeżenie: (0%) ![]() ![]() |
![]() ![]() ![]() ![]() |
|
|
![]()
Post
#8
|
|
Grupa: Zarejestrowani Postów: 5 Pomógł: 0 Dołączył: 2.02.2016 Ostrzeżenie: (0%) ![]() ![]() |
Najłatwiej wyśmiać gorzej pomóc.
|
|
|
![]()
Post
#9
|
|
![]() Grupa: Moderatorzy Postów: 36 557 Pomógł: 6315 Dołączył: 27.12.2004 ![]() |
Dostales pomoc. Musisz miec php 5.4 lub nowsze.
Zas jakis komentarz przy jakis pluginie nie oznacza jaka masz wersje php.... By sprawdzic jaką masz wersje php juz ci napisano czego masz uzyc: phpinfo() lub phpversion() Zamiast wiec narzekac, poprostu sprawdź normalnie jak ci napisano. -------------------- "Myśl, myśl, myśl..." - Kubuś Puchatek || "Manual, manual, manual..." - Kubuś Programista "Szukaj, szukaj, szukaj..." - Kubuś Odkrywca || "Debuguj, debuguj, debuguj..." - Kubuś Developer |
|
|
![]()
Post
#10
|
|
Grupa: Zarejestrowani Postów: 5 Pomógł: 0 Dołączył: 2.02.2016 Ostrzeżenie: (0%) ![]() ![]() |
po zmianie wersji na wyższa 5.5.5 pojawił się inny komunikat
Warning: mysql_real_escape_string(): Access denied for user 'xxx'@'xxx' (using password: NO) in /..../statpress.php on line 1191 Warning: mysql_real_escape_string(): A link to the server could not be established in /..../statpress.php statpress.php on line 1191 Warning: mysql_real_escape_string(): Access denied for user 'xxx'@'xxx' (using password: NO) in /..../statpress.php/statpress.php on line 1194 Warning: mysql_real_escape_string(): A link to the server could not be established in /..../statpress.php /statpress.php on line 1194 Warning: mysql_real_escape_string(): Access denied for user 'xxx'@'xxx' (using password: NO) in /..../statpress.php/statpress.php on line 1197 Warning: mysql_real_escape_string(): A link to the server could not be established in /..../statpress.php statpress.php on line 1197 Line 1191 zaczyna się od $urlRequested=mysql_real_escape_string($urlRequested); możecie z tym mi pomóc? CODE // URL (requested)
$urlRequested=iri_StatPress_URL(); if (eregi(".ico$", $urlRequested)) { return ''; } if (eregi("favicon.ico", $urlRequested)) { return ''; } if (eregi(".css$", $urlRequested)) { return ''; } if (eregi(".js$", $urlRequested)) { return ''; } if (stristr($urlRequested,"/wp-content/plugins") != FALSE) { return ''; } if (stristr($urlRequested,"/wp-content/themes") != FALSE) { return ''; } if (stristr($urlRequested,"/wp-admin/") != FALSE) { return ''; } $urlRequested=mysql_real_escape_string($urlRequested); $referrer = (isset($_SERVER['HTTP_REFERER']) ? htmlentities($_SERVER['HTTP_REFERER']) : ''); $referrer=mysql_real_escape_string($referrer); $userAgent = (isset($_SERVER['HTTP_USER_AGENT']) ? htmlentities($_SERVER['HTTP_USER_AGENT']) : ''); $userAgent=mysql_real_escape_string($userAgent); $spider=iriGetSpider($userAgent); if(($spider != '') and (get_option('statpress_donotcollectspider')=='checked')) { return ''; } if($spider != '') { $os=''; $browser=''; } else { // Trap feeds $feed=iri_StatPress_is_feed(get_bloginfo('url').$_SERVER['REQUEST_URI']); // Get OS and browser $os=iriGetOS($userAgent); $browser=iriGetBrowser($userAgent); list($searchengine,$search_phrase)=explode("|",iriGetSE($referrer)); } // Country (ip2nation table) or language $countrylang=""; if($wpdb->get_var("SHOW TABLES LIKE 'ip2nation'") == 'ip2nation') { $sql='SELECT * FROM ip2nation WHERE ip < INET_ATON("'.$ipAddress.'") ORDER BY ip DESC LIMIT 0,1'; $qry = $wpdb->get_row($sql); $countrylang=$qry->country; } if($countrylang == '') { $countrylang=iriGetLanguage($_SERVER['HTTP_ACCEPT_LANGUAGE']); } // Auto-delete visits if... if(get_option('statpress_autodelete') != '') { $t=gmdate("Ymd",strtotime('-'.get_option('statpress_autodelete'))); $results = $wpdb->query( "DELETE FROM " . $table_name . " WHERE date < '" . $t . "'"); } if ((!is_user_logged_in()) OR (get_option('statpress_collectloggeduser')=='checked')) { if($wpdb->get_var("SHOW TABLES LIKE '$table_name'") != $table_name) { iri_StatPress_CreateTable(); } $insert = "INSERT INTO " . $table_name . " (date, time, ip, urlrequested, agent, referrer, search,nation,os,browser,searchengine,spider,feed,user,timestamp) " . "VALUES ('$vdate','$vtime','$ipAddress','$urlRequested','".addslashes(strip_tags($userAgent))."','$referrer','" . addslashes(strip_tags($search_phrase))."','".$countrylang."','$os','$browser','$searchengine','$spider','$feed','$userdata->user_login','$timestamp')"; $results = $wpdb->query( $insert ); } } function iriStatPressUpdate() { global $wpdb; $table_name = $wpdb->prefix . "statpress"; $wpdb->show_errors(); print "<div class='wrap'><table class='widefat'><thead><tr><th scope='col'><h2>".__('Updating...','statpress')."</h2></th><th scope='col' style='width:150px;'>".__('Size','statpress')."</th><th scope='col' style='width:100px;'>".__('Result','statpress')."</th><th></th></tr></thead>"; print "<tbody id='the-list'>"; # check if ip2nation .sql file exists if(file_exists(ABSPATH.'wp-content/plugins/'.dirname(plugin_basename(__FILE__)).'/ip2nation.sql')) { print "<tr><td>ip2nation.sql</td>"; $FP = fopen (ABSPATH.'wp-content/plugins/'.dirname(plugin_basename(__FILE__)).'/ip2nation.sql', 'r' ); $READ = fread ( $FP, filesize (ABSPATH.'wp-content/plugins/'.dirname(plugin_basename(__FILE__)).'/ip2nation.sql') ); $READ = explode ( ";\n", $READ ); foreach ( $READ as $RED ) { if($RES != '') { $wpdb->query($RED); } } print "<td>".iritablesize("ip2nation")."</td>"; print "<td><IMG style='border:0px;width:20px;height:20px;' SRC='/wp-content/plugins/".dirname(plugin_basename(__FILE__))."/images/ok.gif'></td></tr>"; } |
|
|
![]() ![]() |
![]() |
Aktualny czas: 19.08.2025 - 12:27 |