Include administrator in author list
change in_array(‘contributor’,$user->roles) to (in_array(‘contributor’,$user->roles) || in_array(‘administrator’,$user->roles))
change in_array(‘contributor’,$user->roles) to (in_array(‘contributor’,$user->roles) || in_array(‘administrator’,$user->roles))
Try the following. Replace ereg(‘/\edit\.php’, $_SERVER[‘REQUEST_URI’]) with preg_match(‘/edit.php/’, $_SERVER[‘REQUEST_URI’]) And also change if(isset($_POST[$meta_box[‘name’].’_value’])){ $data = $_POST[$meta_box[‘name’].’_value’]; } to if(isset($_POST[$meta_box[‘name’].’_value’])){ $data = $_POST[$meta_box[‘name’].’_value’]; } else $data = “”;
PHP call div with function
You have some problems with the way you are doing it. The following line reads your settings in… $settings = get_option( ‘eddreldlc_options’, $eddreldlc_options ); So settings looks like: array( ‘loop_true’ => array( ‘value’ => ‘true’, ‘label’ => ‘True’ ), ‘loop_false’ => array( ‘value’ => ‘false’, ‘label’ => ‘False’ ) ); Your loop looks like the … Read more
Two thoughts: 1) Doesn’t isotope have a method for adding “stuff”? 2) What about adding a custom field or two, to the product and then use those to create an element before / after that product? 3) Instead of injecting the message via the loop just create the div / wrapped with some – id … Read more
WordPress pagination broken on blog page, working for search results page
The short answer is that there isn’t one. WordPress templating consists mostly of raw PHP and Template Tags API. The API is more focused on outputting specific content, than producing specific HTML. As result the technique is pretty much unknown in WordPress development. It doesn’t mean that you can’t use one, but it’s just not … Read more
I’m not sure I fully understand what you’re trying to achieve, but I’d suggested to attempt to construct the field’s ID and name from data you’ve got available from the source code of the generated widget. If you check out the code, you’ll find that by every widget, there’s a hidden form field called id_base … Read more
The problem you are seeing is that you have your declarations of the same importance from a CSS standpoint. If you add another style to give it more preference: #cqrm-current-item-list tr.cue-deletion.cue-coming-soon, #cqrm-current-item-list tr.cue-deletion.tr.cue-coming-soon *{ background-color: #fbb !important; filter: alpha(opacity=100) !important; } Or move the cue-deletion below the cue-comingsoon declaration you should find things work as … Read more
I found the errors thanks to the help from @Milo @Milo’s query on catno pointed me to my error with my first query involving catno, and I also noticed a double equals in $catno == $row[0]; when it should be $catno = $row[0]; Final coding is function QueryStock($cat) { $query = “SELECT * FROM stock … Read more