Quantcast
Channel: WordPress › Support » Forum: Hacks - Recent Topics
Viewing all 8245 articles
Browse latest View live

ilfungo on "unable to create new administartors users"

$
0
0

Hi, trying to make a capability and role setup I install and used different plugins:
Capability Manager
Advanced Access Manager
Groups
Members
and finally I keep and I use Advanced Access Manager .
Noweverithing almost fine to go online but I have two problems: I would like to setup Shop Manager (woocommerce user) to create others Shop Managers, and I find out Administrator can't create other administrators. Any idea of what I should do to manage this situation?


Alessiosester on "Logs Meaning"

$
0
0

hi

I have some logs with this line with unknown ip adress

POST /wp-admin/admin-ajax.php HTTP/1.1" 200 301

What does it means?

Thanks in advance

MortenEgholt on "WordFense: "core file modified: wp-includes/version.php""

$
0
0

Hello,

I got the following alert today: "WordPress core file modified: wp-includes/version.php." Does anybody know what it means? I think it is a false positive, but I'd like to be sure. In the WordFense plugin it displays this as the modification:

34	*/ 	34	*/
35	$required_mysql_version = '5.0'; 	35	$required_mysql_version = '5.0';
36	 	                                                36
37 	 	                                                37	$wp_local_package = 'da_DK';

It seems like it is only the language that has been updated. I did some translation a few days ago, maybe that is why the plugin reacts? Can anybody clear this up for me please.

Best regards,

Morten.

FadingMusic on "Need help make changes to a plugin's code"

Alessiosester on "Logs meaning"

$
0
0

Hi,

I have found some unknown ip adresses with this line code

POST /wp-admin/admin-ajax.php HTTP/1.1" 200 301

What does it means?

Thanks in advance

Alex

Educated Savage on "Adding"

$
0
0

So, I'm trying to change the footer content of the theme I'm using and I found the spot where I want to change it. I'm trying to change the footer content on http://www.heatherwoodward.org. So far, I've gotten it to display the text Privacy Policy. It's in here where it says "echo "Privacy Policy";

function catchbase_footer_content() {
	//catchbase_flush_transients();
	if ( ( !$catchbase_footer_content = get_transient( 'catchbase_footer_content' ) ) ) {
		echo '<!-- refreshing cache -->';

		$catchbase_content = catchbase_get_content();

		$catchbase_footer_content =  '
    	<div id="site-generator" class="two">
    		<div class="wrapper">
    			<div id="footer-left-content" class="copyright">' . $catchbase_content['left'] . '</div>

    			<div id="footer-right-content" class="powered">' . $catchbase_content['right'] . '</div>
			</div><!-- .wrapper -->
		</div><!-- #site-generator -->';

    	set_transient( 'catchbase_footer_content', $catchbase_footer_content, 86940 );
    }

    echo "Privacy Policy";
}
add_action( 'catchbase_footer', 'catchbase_footer_content', 100 );

I want to change that so it has three text links in it. What I'm trying to do would look something like this in HTML

<a href = "http://www.heatherwoodward.org/about">Copyright 2015 by Heather Woodward</a> - <a href = "http://www.heatherwoodward.org/privacy-policy">Privacy Policy</a> - <a href = "http://www.heatherwoodward.org/terms-and-conditions">Terms and Conditions</a>

Of course, when I do that, I just crash my site. I'm very slowly learning PHP and I'm sure the answer is really obvious, but I sure could use some help.

Thanks so much!

-- Charlene

oliverm on "action to insert wrapper div *after* heading on archive page"

$
0
0

Hi all

Is there an action hook that will allow me to insert a wrapper div *after* the heading on an archive page?

I have this code which does what I want but it inserts the wrapper before the heading. This results in the heading being included in the div. The results of which can be seen here
http://www.marshallgames.co.uk/product-category/manufacturers/victory-point-games/

***************************
function start_wrapper_here() { // Start wrapper
if (is_product_category()) { // Wrapper for a product category page
echo '<div class="product-category-wrapper">';
}
}
add_action( 'woocommerce_before_main_content', 'start_wrapper_here', 20 );
****************************

However, I want it to look more like this page where the white background div begins after the H1 tag on that page.
http://www.marshallgames.co.uk/brand/x-wing/

Any suggestions as to how I can do this with an action?

Olly

Guido on "Using a session in plugin"

$
0
0

Hi,

I have a contactform plugin containing a file with plugin funcions and in that file I use function 'include' to include a second file with the contents of the form.

That second form starts with a 'session_start' because of a certain function I use in frontend. In frontend a session is start when user visits the contactform page. The session is destroyed again after form is succesfully send.

My question:
Because lately I'm having some pageload problems in backend I'm wondering whether the session can cause this or not? I think so, because when I remove it from the second file, pageload is ok again.
How to solve this?

Guido


Somedude77 on "Passing an array from a loop in one partial to another partial"

$
0
0

I can't figure out how to do this to save my life.

In my index.php file, before the loop, I created a global variable,

global $index_of_ids

Once the loop starts, I put all the post id's from the loop, into it.

$index_of_ids = $post->ID;

I also wrote a plugin for a sidebar widget that uses wp_query, and I want to exclude the posts in the global $index_of_ids from it (just using the wp_query arguments).

But the plugin cannot recognize that the global variable exists!

How can I access it from the plugin?

Thank you

leonardus on "timeout password protected page wp 3.9.2"

$
0
0

Have you a suggestion for setting timeout in protected password page?
if I change setting in wp-pass or in wp-login, with an update my modify are overwritten...
is there a plugin to do this?

sorry for my english... thank you.

Viamultimedia on "Problem queries count post meta"

$
0
0

Hello,

I am looking for some help for a query.
I have a custom post type name listings. I have a post meta width meta key(villes).

I want to show the count of villes (not post count in villes) who have a post.

Is it possible and how can I do ?

Thank you !

javawpscript on "Redesigning My Search Results"

$
0
0

I have got the Twenty Ten WordPress Theme but I don't want to use the current search design. I have found out if I do a normal search for example cheese (?s=cheese) but if I do (news?s=cheese) then it will search that parent page and child pages. I was wondering if there was anyway to get the search looking like the bbc.co.uk search design. I know that it might need editing in the Theme Editor and that is fine!

PS: I use a Multisite with Only 1 Site.

Begin on "Tweak visual editor"

$
0
0

Is it possible to customise the options in the dropdown list of styles (Heading 1 heading 2...) of the wordpress visual editor?

robsbots on "Could a dev check out my first VERY short plugin ? Thanks"

$
0
0

I have written a very simple plugin and as it is my first I would like a wp dev to have a quick look and see if it is likley to break anyones site. It is litterally 15 lines long including the comments. I would like to release it but do not wish to damage anyones site. The plugin just adds an http header to every WP page.

The code is published here :- http://www.robsbots.co.uk/techtips/a-simple-wp-plugin/

Many thanks.

Rob

Mike Howard on "Problem with 'save_post' hook not running"

$
0
0

I have a custom post type, with a custom meta box which contains a number of input fields.

The meta box is displaying fine but when completing all the fields the data is not saving, in fact, the function I call with the save_posthook does not appear to be running at all...

I use the register_meta_box_cb to define my function which adds the meta box for me. I then use the following in my attempt to save the custom data...

add_action( 'save_post', 'my_save_function', 10, 2 );
function my_save_function( $post_id, $post )	{
foreach( $_POST as $meta_key => $new_meta_value )	{
if( substr( $meta_key, 0, 6 ) == 'venue_' )	{ // This is verified and correct
update_post_meta( $post_id, $meta_key, $new_meta_value );
}
}
}

Been staring at this and searching the codex and Google for a couple of hours now with no progress... Whatever I put in that save function just does not execute. I have tried die() and error_log at the very top of the function to ensure my checks are not the problem... but nothing. (the function above is a cut down version to what I really have)


EnnoK on "Create own custom menu item"

$
0
0

Hello!

How do I create my own custom menu items to appear under Appearance->Menus (like the "Pages", "Links" and "Categories" items)?

I got my plugin working to browse posts by users and now I am looking for an easy way to implement this into the custom menus.

Best regards
Enno

Liv on "Change title tag with custom fields for pages, posts and woocommerce products."

$
0
0

Hi,

I'd like to be able to change the title tag individually for pages, posts, category pages and products (woocommerce) by using a custom field.

Is there anyone that knows how to accomplish this without a SEO plugin?

Cheers!

Liv

canutedechou on "Use post Excerpt to insert a URL"

$
0
0

Hi
I want to use the excerpt of a post in order to use that content on a

<a href="<?php the_excerpt(); ?>">Link</a>

But it only generates blank spaces and the url is not well inserted, any idea how to fix this?
thanks in advance

Please Add Screenshots on "query posts and exclude current post"

$
0
0

I've tried various things like below...

<?php
$args = array (
	'gender' => 'female',
	'seeking' => 'male-2',
	'state' => 'south-australia',
	'posts_per_page' => '4',
        'post__not_in' => array($post->ID),
	'order' => 'ASC',
	'orderby' => 'rand',
);
?>
<?php $query = new WP_Query( $args ); ?>
<?php
if ( $query->have_posts() ) {
	while ( $query->have_posts() ) {
		$query->the_post();
?>

loop stuff goes here

<?php wp_reset_postdata(); ?>

But I can't exclude the current post from appearing in this query (sidebar).

What am I doing wrong?

Thanks heaps

Pete

ChinchillaSanchez on "Replace Password Protect with QR code?"

$
0
0

I'm trying to develop a plugin that creates a bitcoin paywall. I want to create a checkbox similar to the Password Protect Visibility option. Instead a password form appearing, I want a QR code linking to my bitcoin wallet. What would the best way to implement this be?

Viewing all 8245 articles
Browse latest View live


Latest Images