I upgraded my PHP to 7.0 and after this I have this message in the header of my website:  Warning: Declaration of description_walker::start_el($output, $item, $depth, $args) should be compatible with Walker_Nav_Menu::start_el(&amp;$output, $item, $depth = 0, $args = Array, $id = 0) in /homepages/2/d444683358/htdocs/wp-content/themes/zend/functions.php on line 59   Here is the line 59 in functions.php:  $output .= apply_filters( 'walker_nav_menu_start_el', $item_output, $item, $depth, $args );   I'm not a coder so not sure what needs to be done to fix this?  Thanks for your help
11903
I'm currently working on a WordPress site and whenever in the admin I go the Appearance > Menus page I get the following error:     ErrorException: Runtime Notice: Declaration of Walker_Nav_Menu_Edit::start_lvl() should be compatible with that of Walker_Nav_Menu::start_lvl() in wp-admin/includes/nav-menu.php line 203   It seems like some sort of PHP compatibility issue. I'm running PHP 5.3.10 on my local dev machine.  What would be the best way to remedy this problem?
4846
There's something wrong with this code:  \newenvironment{Tbl} {\begin{tabularx}{\textwidth}{|l|X|} \hline} {\end{tabularx}}   but this is fine:  \newenvironment{Tbl} {\begin{tabular}{|l|l|} \hline} {\end{tabular}}   Why? And how can I get the first to work?  Here is the full LaTeX file:  \documentclass[a4paper, 12pt]{article} \usepackage{tabularx}  \newenvironment{Tbl} {\begin{tabularx}{\textwidth}{|l|X|} \hline} {\end{tabularx}}  \begin{document}  \begin{Tbl} \end{Tbl}  \end{document}      latex test.tex   produces:  This is pdfTeXk, Version 3.141592-1.40.3 (Web2C 7.5.6)  %&amp;-line parsing enabled. entering extended mode (./test.tex LaTeX2e &lt;2005/12/01&gt; Babel &lt;v3.8h&gt; and hyphenation patterns for english, usenglishmax, dumylang, noh yphenation, arabic, basque, bulgarian, coptic, welsh, czech, slovak, german, ng erman, danish, esperanto, spanish, catalan, galician, estonian, farsi, finnish,  french, greek, monogreek, ancientgreek, croatian, hungarian, interlingua, ibyc us, indonesian, icelandic, italian, latin, mongolian, dutch, norsk, polish, por tuguese, pinyin, romanian, russian, slovenian, uppersorbian, serbian, swedish,  turkish, ukenglish, ukrainian, loaded. (/usr/share/texmf/tex/latex/base/article.cls Document Class: article 2005/09/16 v1.4f Standard LaTeX document class (/usr/share/texmf/tex/latex/base/size12.clo)) (/usr/share/texmf/tex/latex/tools/tabularx.sty (/usr/share/texmf/tex/latex/tools/array.sty)) (./test.aux)) Runaway argument?  \par  ! File ended while scanning use of \TX@get@body. &lt;inserted text&gt;                  \par  &lt;*&gt; test.tex  ?
24902
I get this error due to one of the plugins which I rely on.   Notice:  wp_enqueue_style was called incorrectly. Scripts and styles should not be registered or enqueued until the wp_enqueue_scripts, admin_enqueue_scripts, or init hooks.   What does this error mean and how do you fix it?  Mind due that this is not a critical error. It only appears when I put WP into debug mode.   The full plugin-code is below.   It's one heck of a plug in that makes it a breeze to deal with the highly complicated and hierarchical cats. I'm posting it not just for the sake of debugging where the bloddy error is but also to hope that it helps someone.   &lt;?php /*  **************************************************************************  Plugin Name:  Category Collapse Description:  Makes children categories hidden on the Write screens until an icon is clicked. Version:      2009.02.12 Author:       Viper007Bond Author URI:   http://www.viper007bond.com/  **************************************************************************/  class CategoryCollapse {      // Plugin initialization     function CategoryCollapse() {         if ( !is_admin() ) return;          wp_enqueue_style( 'category-collapse', plugins_url('/category-collapse/category-collapse.css'), array(), '2009.02.12', 'screen' );         add_action( 'admin_head', array(&amp;$this, 'edit_form_advanced') );     }       // Output the Javascript (it's not in an external file due to the dynamic image URLs)     function edit_form_advanced() { ?&gt; &lt;script type="text/javascript"&gt; /* &lt;![CDATA[ */     jQuery(document).ready(function($){         $("#categorychecklist li").addClass("catcolpadding");         $("#categorychecklist ul.children").hide().parent("li").removeClass("catcolpadding").addClass("cathaschildren catcollapsed").prepend('&lt;img class="catcoltoggler" src="&lt;?php echo plugins_url('/category-collapse/images/plus.gif'); ?&gt;" alt="+" title="Show Children" /&gt;');         $("#categorychecklist .catcoltoggler").click(function(){             var parent = $(this).parent("li.cathaschildren");             if ( parent.hasClass("catcollapsed") ) {                 $(this).attr({ src: "&lt;?php echo plugins_url('/category-collapse/images/minus.gif'); ?&gt;", alt: "-", title: "Hide Children" });                 parent.removeClass("catcollapsed").addClass("catuncollapsed").children("ul.children").slideDown();             } else {                 $(this).attr({ src: "&lt;?php echo plugins_url('/category-collapse/images/plus.gif'); ?&gt;", alt: "+", title: "Show Children" });                 parent.removeClass("catuncollapsed").addClass("catcollapsed").children("ul.children").slideUp();             }         });         $(".cat-checklist li").addClass("catcolpadding");         $(".cat-checklist ul.children").hide().parent("li").removeClass("catcolpadding").addClass("cathaschildren catcollapsed").prepend('&lt;img class="catcoltoggler" src="&lt;?php echo plugins_url('/category-collapse/images/plus.gif'); ?&gt;" alt="+" title="Show Children" /&gt;');         $(".cat-checklist .catcoltoggler").click(function(){             var parent = $(this).parent("li.cathaschildren");             if ( parent.hasClass("catcollapsed") ) {                 $(this).attr({ src: "&lt;?php echo plugins_url('/category-collapse/images/minus.gif'); ?&gt;", alt: "-", title: "Hide Children" });                 parent.removeClass("catcollapsed").addClass("catuncollapsed").children("ul.children").slideDown();             } else {                 $(this).attr({ src: "&lt;?php echo plugins_url('/category-collapse/images/plus.gif'); ?&gt;", alt: "+", title: "Show Children" });                 parent.removeClass("catuncollapsed").addClass("catcollapsed").children("ul.children").slideUp();             }         });     }); /* ]]&gt; */ &lt;/script&gt; &lt;?php     } }  // Start this plugin once all other plugins are fully loaded add_action( 'plugins_loaded', create_function( '', 'global $CategoryCollapse; $CategoryCollapse = new CategoryCollapse();' ) );  ?&gt;
8189
I have a WordPress website that I recently discovered had this error on the login page:     ERROR: Cookies are blocked due to unexpected output. For help, please   see this documentation or try the support forums.   I can only access the login page from wp-login.php, since /wp-admin/ displays a blank white page.  I've searched the web and tried many things with no success:   Removing ?&gt; and space at end of the functions.php Ensuring both functions.php and wp-config.php had no spaces at beginning or end of file Opening wp-config.php and functions.php in Notepad++ and converting to UTF-8 (people recommend 'without BOM' but that is only an option in the newest version of Notepad++ - I'm guessing UTF-8 does that now) I've set WP_DEBUG to true and have received no errors in debug.log,  except for 2 that relate to when I hadn't fully uploaded some files. That particular error mentioned nav-menu.php; this confirmed that it is reporting errors, just not related to my login issues I renamed each plugin folder with _tmp at the end to try and rule out any plugins causing the problem I also renamed the plugins folder to rule out all plugins at the same time   Given these things I've tried, and that I'm not receiving any PHP errors, what else could I try?
28523
Here's a PHP example of mine. Can anyone find a shorter/easier way to do this?  &lt;? foreach($posts as $post){?&gt;     &lt;div class="&lt;?=($c++%2==1)?‘odd’:NULL?&gt;"&gt;         &lt;?=$post?&gt;     &lt;/div&gt; &lt;? }?&gt;  &lt;style&gt;     .odd{background-color:red;} &lt;/style&gt;   Examples in other languages would be fun to see as well.
87901
There is some conflict or error I don't understand. I can skip it and nothing visible happens. The output is okay and everything seems to be fine. Still I would like to get rid of the error message. If I run the following minimal example:   \documentclass[]{scrbook}  \usepackage[applemac, grafiken]{tahbiblatex} \usepackage[ngerman]{babel}   \begin{document}  Testing äüöaüä.  \end{document}   I get the error message:      ! Missing = inserted for \ifnum. &lt;to be read again&gt;                     , l.4 \usepackage                [ngerman]{babel} ?  ! Missing number, treated as zero. &lt;to be read again&gt;                     , l.4 \usepackage                [ngerman]{babel}   Here is my .sty file:  \NeedsTeXFormat{LaTeX2e}\relax \ProvidesPackage{tahbiblatex}[2012, by tah modified by sm]  \RequirePackage{ifthen}  \DeclareOption{latin1}{\PassOptionsToPackage{\CurrentOption}{inputenc}} \DeclareOption{applemac}{\PassOptionsToPackage{\CurrentOption}{inputenc}} \DeclareOption{cp850}{\PassOptionsToPackage{\CurrentOption}{inputenc}} \DeclareOption{utf8}{\PassOptionsToPackage{\CurrentOption}{inputenc}}  \DeclareOption{dvi}{% \newif\ifpdf \ifx\pdfoutput\undefined     \pdffalse \else     \pdfoutput=0     \pdftrue \fi}  \newcounter{Grafiken}\setcounter{Grafiken}{0} \DeclareOption{grafiken}{\setcounter{Grafiken}{1}}  \newcounter{Randausgleich}\setcounter{Randausgleich}{0} \DeclareOption{randausgleich}{\setcounter{Randausgleich}{1}}  \newcounter{Tabellen}\setcounter{Tabellen}{0} \DeclareOption{tabellen}{\setcounter{Tabellen}{1}}  \newcounter{Sync}\setcounter{Sync}{0} \DeclareOption{sync}{\setcounter{Sync}{1}}  \ProcessOptions  \RequirePackage{fixltx2e} \RequirePackage{inputenc} \RequirePackage[T1]{fontenc} \RequirePackage[T1]{url} \RequirePackage{setspace} %\RequirePackage[german]{varioref} \RequirePackage{textcomp}  \newcommand{\urlangabe}[2]{% $\langle$\url{#1}$\rangle$ -- Zugriff am #2}  \def\hierlockern {\begingroup \def\par{\endgraf\endgroup}%   \tolerance 1414%   \hbadness 1414%   \emergencystretch 1.5em%   \hfuzz 0.3pt%   \vfuzz \hfuzz%   \raggedbottom% }  \newcommand{\alleslockern}{%   \tolerance 1414%   \hbadness 1414%   \emergencystretch 1.5em%   \hfuzz 0.3pt%   \vfuzz \hfuzz%   \raggedbottom% } \ifthenelse{\value{Grafiken}=1}   {   \ifx\pdfoutput\undefined \newcount\pdfoutput \fi   \ifcase\pdfoutput       \RequirePackage[dvips]{graphicx}       \DeclareGraphicsExtensions{.eps}       \typeout{Paket tah Meldung: Die Option `grafiken' fuer DVI wurde gewaehlt.}% \else     \RequirePackage[pdftex]{graphicx}     \DeclareGraphicsExtensions{.jpg,.tif,.png,.pdf}     \typeout{Paket tah Meldung: Die Option `grafiken' fuer PDF wurde gewaehlt.}%   \fi}   {}  \ifthenelse{\value{Sync}=1}   {     \ifx\pdfoutput\undefined \newcount\pdfoutput \fi     \ifcase\pdfoutput     \RequirePackage{srcltx}     \typeout{Paket tah Meldung: Die Option `sync' fuer DVI wurde gewaehlt.}%     \else     \RequirePackage{pdfsync}     \typeout{Paket tah Meldung: Die Option `sync' fuer PDF wurde gewaehlt.}%     \fi }   {}   \ifthenelse{\value{Randausgleich}=1}   {\typeout{Paket tah Meldung: Die Option `randausgleich' wurde gewaehlt.}%   \RequirePackage[activate]{pdfcprot}}   {}  \ifthenelse{\value{Tabellen}=1}   {\typeout{Paket tah Meldung: Die Option `tabellen' wurde gewaehlt.}%   \RequirePackage{tabularx}   \RequirePackage{ragged2e}   \RequirePackage{dcolumn}   \RequirePackage{booktabs}   \newcolumntype{L}{&gt;{\RaggedRight\hspace{0pt}\arraybackslash}l}   \newcolumntype{Y}{&gt;{\RaggedRight\hspace{0pt}\arraybackslash}X}   \newcolumntype{d}[1]{&gt;{\DC@{.}{,}{#1}}l&lt;{\DC@end}}   }   {}    \endinput   I also don't really need all the features. So it would be nice to reduce it to minimal features, which are needed..
104321
The international Stack Overflow sites in Spanish, Portuguese, Russian, and Japanese seem to have a bug in their quick site descriptions (under their titles), for they all start with the word  For...  in English, instead of their respective languages As an example, the Spanish Stack Overflow site description is:  For programadores y profesionales de la informática  Obviously, this isn't something too big of a deal, but since they offer those sites in their respective languages, it would be nice if this issue were fixed. You can see this under &quot;More communities&quot; in the top bar.    You can also see this on the  page, where the descriptions begin with  Q&amp;A for...
105801
I have been trying but its not working.  but if i try   &lt;?php echo do_shortcode("[mimo]"); ?&gt; &lt;?php echo do_shortcode("[mibaby]"); ?&gt;   it will work fine.  But to apply it in post content using [mimo] [mibaby]  it won't work.  Here is the Functions i am using...  function wpb_custom_new_menuw() {   remove_filter( 'the_content', 'wpautop' ); } add_shortcode('mibaby', 'wpb_custom_new_menuw');    function wpb_custom_new_menu() {   remove_filter( 'the_excerpt', 'wpautop' ); } add_shortcode('mimo', 'wpb_custom_new_menu');
111653
That's a freaking bad practice I must say. Spent last two hours finding a solution to remove actions and filters added via Anonymous functions.    This is the code used on a Parent Theme, and I need to remove it.  /**  * Add custom columns to admin comments grid  *  * Rate that user set.  */ add_filter( 'manage_edit-comments_columns', function( $default ) {     $columns['smr_comment_rate']  = __( 'Rate', 'txtdmn' );      return array_slice( $default, 0, 3, true ) + $columns + array_slice( $default, 2, NULL, true ); });   Got , played with it heavily, but no help. So, is there any other alternative that will remove actions/filters added via anonymous functions?  Thanks
52955
I've seen this convention pretty much everywhere, and, at times, it comes close to driving me nuts:  &lt;?php //The loop ?&gt; &lt;?php while ( have_posts() ) : the_post(); ?&gt;     &lt;?php the_content(); ?&gt; &lt;?php endwhile; // end of the loop. ?&gt;   Where the &lt;?php and closing ?&gt; are on every single line, even if there is no intervening HTML code.    My question is: Why?  Why include all these extra tags?      To me, it seems this convention adds a significant amount of clutter to code, is annoying to follow in the first place, and adds that many more places to accidentally leave out an opening or closing tag.  NOTE  This is code pulled from the Twenty-Twelve theme, the example given by WordPress.
82526
Some compilers (especially C or C++ ones) give you warnings about:  No new line at end of file   I thought this would be a C-programmers-only problem, but github displays a message in the commit view:  \ No newline at end of file   for a PHP file.  I understand the preprocessor thing explained in , but what has this to do with PHP? Is it the same include() thing or is it related to the \r\n vs \n topic?   What is the point in having a new line at the end of a file?
991
I've been told to run this:  ./yiic message ./app/messages/config.php   But I don't understand the ./ meaning, can anyone clarify please.  Note: Believe me, we can't google that. I've tried:  ./ meaning ./ ubuntu  It was the same as nothing. :(
61555
I'm having to update a WP installation for a community organisations from version 2.9.1 to the current 3.9.1.   The installation has a couple of custom built plugins that aren't documented.  I've just performed the WP version update and now I see a warning (Missing argument 2 for wpdb::prepare()) on every page that relates to the following line in the code of one of these custom built plugin:  $rows = $wpdb-&gt;get_results($wpdb-&gt;prepare("SELECT id, name FROM ".$table_name));   From what I've read online, this is due to a change in the coding, that requires 2 values to be sent to wpdb::prepare(), but I've no idea how the line of code given above, needs to be changed.  If someone could help me out, I'd really appreciate it.
63827
In beamer class, when i compile using LaTeX, the output pdf results perfectly the way i expect it to. But when i change it to XeLaTeX, in the lstlisting environment, every tab in the code results in a "^^I"-Placeholder (See output-pdf below). How do I fix this?   if( Bedingung ) {  ^^I//Code, der nur ausgefuehrt wird, wenn die Bedingung wahr ist   }  ^^I^^I   LaTeX-Code (Reduced to the minimum, one frame as an example):  \begin{document}     \begin{frame}[fragile]{if-Statements}         \begin{block}{Syntax}                \begin{lstlisting} if( Bedingung ) {     //Code, der nur ausgefuehrt wird, wenn die Bedingung wahr ist }                    \end{lstlisting}         \end{block}         \begin{block}{Logik}                 \begin{itemize}                  \item Alles innerhalb eines if-Blocks wird nur ausgeführt, wenn die Bedingung (in Klammern) wahr ist.             \end{itemize}         \end{block}     \end{frame} \end{document}
103846
As you know default wrapper for menu item in Drupal 7 can be modified via function theme_menu_link().  by overriding   theme_menu_link($variables) {}    function we can modify the rendered html output of menu link but it will change all of menu items that their #theme attribute is set to this function. for example in main menu, each item has menu_link__main_menu value in it's #theme attribute.  Now I want to create a custom wrapper function in my theme.  I searched and I found I must create a function with structure like  theme_menu_link($variables) {}   and also I must REGISTER the function name in my theme.  For registration, I used function theme_theme() {}  function theme_theme() {return array('custom_menu_item_wrapper' =&gt; array());}   ** theme is replaced by name of theme ** custom_menu_item_wrapper is the name of my function for wrapping operation  But I don't know, how should I define parameters in theme function registration because when custom_menu_item_wrapper($variables) function is called $variables is NULL
113113
I just updated Drupal core from 7.4 to 7.26. After running update.php site stopped working – both public and admin part. When I load it fatal error occurs:     Fatal error: Call to undefined function _system_default_theme_features() in /[drupal_path]/includes/theme.inc on line 1422   and when I reload it another fatal error apperars:     Fatal error: Call to a member function getDirectoryPath() on a non-object in /[drupal_path]/modules/image/image.module on line 83   next reload – first error, one more – second. Also, second error is loading much faster.  And one more thing, after applaying update.php I got one failed, I don't know if this is connected:     media_gallery module      Update #7009      Failed: FieldException: Próba aktualizacji egzemplarza nieistniejącego pola media_gallery_media. w field_update_instance() (linia 557 z /[drupal_path]/modules/field/field.crud.inc).   which is something like:     Failed: FieldException: Attempt to update an instance of a nonexistent field media_gallery_media. in field_update_instance() (line 557 in /[drupal_path]/modules/field/field.crud.inc).   PHP Version 5.5.6  I was trying disabling some modules from db (especially image.module, media_gallery already was disabled), but this did't help.  Any tips where the problem is? Thx in advance.
76283
Very new to Tex. Trying to get the most basic doc to work. Not matter what I do I always get an "Undefined control sequence" at line 1 of my document. As of now, I am only trying to build the following:  \documentclass{article} \begin{document} This is a test of the article \end{document}   Full error is:  This is pdfTeX, Version 3.1415926-2.5-1.40.14 (TeX Live 2013)  restricted \write18 enabled. entering extended mode (./example.tex ! Undefined control sequence. l.1 \documentclass                   {article} ?   I have tried many other variations, including \usepackage directives that people mentioned - nothing every varies.