How to crop featured image in different sizes?
You need to define other sizes with this function
You need to define other sizes with this function
its very likely that somewhere in your theme, perhaps in your navigation or footer, you are linking something like <a href=”https://wordpress.stackexchange.com/questions/254739/Contact-Us”> which will then link to the subdirectory. You need to find those issues and fix it with something like <a href=”https://wordpress.stackexchange.com/Contact-Us”> or <a href=”https://wordpress.stackexchange.com/questions/254739/<?php echo get_site_url(); ?>/Contact-Us”> Without seeing code, it’s hard to tell … Read more
Since this is in your plugins, accessing global should work unless you’re calling the file externally. Anyway since it’s not working, you’ll have to include wp-config.php. Make sure your file path is proper. Also if it doesn’t work, put include statement inside your save function.
I believe (off of top of head) that theme authors cannot ‘force’ attribution code as part of the theme. The theme must allow for removal of the attributions. (Can’t find the doc standards for this at the moment.) You should be able to edit the theme code that shows the attribution, although that is not … Read more
You don’t need if (is_home) – the homepage doesn’t use page.php as a template, and you’re checking for page ID anyway, which the homepage shouldn’t match. To check what page you’re on you can use is_page() with the page ID. if(is_page(1111)) { display text 01; } elseif(is_page(2222)) { display text 02; }
You either need to tell jQuery that you expect a json response from the server: $(“#txt-cmt”).keypress(function(e) { if (e.which == 13) { var comment = $(this).val(); var message = { action: ‘show_comment’, user_message: comment }; $.post(ajaxUrl.url, message, function(data) { console.log(data.user_name); }, ‘json’); } }); or you need to parse the response as json with JSON.parse().
Found it… $date = get_post_meta( $post->ID, ‘CUSTOM-FIELD-HERE’, true ); if( $date != ” ) { echo date( “l jS F Y”, strtotime( $date ) ); }
The theme name is showing in the post image because, I’m guessing, you haven’t uploaded a featured image for that post and it’s therefore displaying a placeholder image instead. The post text (excerpt) is showing shortened due to a theme setting or how the theme intends it to look and nothing at all to do … Read more
To display post title, you could use: <a href=”https://wordpress.stackexchange.com/questions/310842/<?php the_permalink(); ?>” title=”<?php the_title_attribute(); ?>”><?php the_title(); ?></a> or alternately, a simple: <?php echo get_the_title(post->$ID); ?>
The best way to have tailored experience is to make people to sign in to the site. Once they are logged in, you can store whatever information in the DB and retrieve it when needed. If you do not want to ask for more than a name, you can generate a wordpress user for them … Read more