- ApiAPI – Top Bar Template – Introduction
- ApiAPI – Single Template – Introduction
- ApiAPI – Footer Template – Introduction
- ApiAPI – Smart Lists – Introduction
- ApiAPI – Thumbnail – Introduction
- ApiAPI – Category top section style – Introduction
- ApiAPI – Category top section template – Introduction
- ApiAPI – Modules – Introduction
- ApiAPI – Blocks – Introduction
- ApiAPI – Header style – Introduction
- ApiUsing the Theme API in plugins
Thank you @Radu for the update. I look forward to the updates to NewsMag..and I may actually also get NewsPaper 6 in the future. I’m just awaiting really cool gallery options in NewsMag (something like what The Voux theme does, where they have a gallery that opens up in a lightbox slider and you can have ads and also your text/description on the right side) – that would definitely set these themes way above all the other magazine style themes out there (it’s one feature lots of bloggers like myself who does lifestyle magazine based blogs keep asking for).
Hi,
Newspaper compared to other themes ads extra data to the menu items (mega menu data) and it may go over the default max_input_vars value which is 1000. You have to change the value inside the php.ini file and restart Apache. After that you could add the phpinfo(); function at the bottom of a template (ex. the Category template) – http://screencast.com/t/YPHJcQle – Open a category page on frontend and look at the bottom for the max_input_vars value to see if it’s changed to 5000. – http://screencast.com/t/TUUKd1sLUw
Also check the host documentation on how to edit the php.ini file, they usually have a guide.
If the menu still doesn’t save try to create a new menu and add the same items on it, the old menu may have some hidden error (from a parameter or something else). If it works delete the old menu and use the new one.
Thank you, Emil G.
Thanks Andrei…
I got some help in another thread from a user and fixed the issue. What I should have been using was my Twitter username “embracedominica”… and not the ID.
It works fine now.
I do have a few other threads I started that I’d like help with tho 🙂
Hi
In case you are using Ad-sense this might be against their policy, to have on dekstop one specific ad, and on mobile different ad. For other ads type’s you can check this link https://forum.tagdiv.com/ads-system-full-guide for more details, and if you want different (non-Adsense) ads on mobile you can paste the ad’s code inside this class:
<div class="td-visible-phone"></div>
Thanks!
-
This reply was modified 11 years by
Andrei L..
-
This reply was modified 11 years by
Andrei L..
-
This reply was modified 11 years by
Andrei L..
-
This reply was modified 11 years by
Andrei L..
-
This reply was modified 11 years by
Andrei L..
-
This reply was modified 11 years by
Andrei L..
-
This reply was modified 11 years by
Andrei L..
Hi,
Unfortunately you will need custom work to achieve this, please check this topic how to add another inline ad – https://forum.tagdiv.com/topic/more-inline-ads-in-post/ if you don’t have basic php experience I suggest to get someone to help you as we cannot provide any type of custom work for the moment, sorry!
Thanks!
Hey,
I Installed W3 Cache Plugin yesterday, and post views stoped working. I saw the threads about activating the Ajax post view count, but it’s still not working.
Is there any other way making this work?
Thanks
website (www.israsport.co.il)
Alin,
I made the change in file indicated of the according to your guidance, But not worked.
I put in “fashion” category as a way to test through the demo content, but not blocked Adsense banners in this category.
I hope this has some other solution
I wait for your help.
Thanks
At least if you provided something as simple as a one line text for widget (Same as topbar), that simply pops the login screen.
Also, I would like to inform you about a glitch on login I found.
If you select the connect/register option. Then go to “forget your password”, and then simply close the login window. Everytime you click the “connect/register” again its stuck on the forget password screen, it doesn’t show the login window, unless you reload screen with “F5”.
Therefore if you send the new password on the email and the user reset on some other browser tab, then the user won’t be able to login on the website, unless he reloads the page…
Hi
In case you are using Ad-sense ads that will not work, but if your ad is an image you can edit it with Photoshop or other program, how you liked. I’ve tried to put the text inside the ad, but is not working, because the ad hide the text. The theme wasn’t designed for something like that.
Thank you!
Friends,
I need to resolve an issue before I start using the Newspaper. I Need to override the Adsense code in a particular category Which groups the posts sensitive to Google’s policy. The intention is que the Adsense banners are Replaced Within the posts in this category by other code of any banner whatsoever. In my old theme I used the following code:
<? php wp_reset_query (); ?>
<? php if (! in_category (‘sexy’)) {?>
<! – ADSENSE CODE BANNER (.. Ads field) ->
<? php}?>
<? php if (in_category (‘sexy’)) {?>
<! – BANNER SUBSTITUTE CODE ->
<? php}?>
I would like to know Which files do I enter this code for each field of the theme Ads tab.
Thank you in advance for your help!
I love this theme, one of the best I have used in 10 years publishing WordPress sites. However, it is unusable on mobile – it take minutes to load – as much as 5 minutes.
I am at a loss to understand why. It loads on desktops and tablets fast, but mobile is useless. My only option is to figure out why or abandon the theme in favor of a better designed responsive theme.
Here is the link to our website http://www.DroningSkies.com in contrast to our other website http://www.DroneCyclone.com
DroningSkies.com is the one with the Newsmag theme installed.
It is not using any cache. What appear to be the problem is a script that is loading first.
Any insights are welcome.
the slider gets messed up by the speedbooster plugin, sooo…here is the code 😉 as I don’t know what I did other than the performance improvement tips ( Is this required? As the performance drops from 93 to 91 after activating it).
<?php
/*
Plugin Name: tagDiv Speed Booster
Plugin URI: http://tagdiv.com
Description: Speed booster for Newspaper and Newsmag theme - It moves the styles and all the scripts of the theme to the bottom when needed. It activates internal theme optimizations for better speed and it adds async js .
Author: tagDiv
Version: 3.2
Author URI: http://tagdiv.com
*/
/*
3.2 - better bbpress support on newsmag
3.1 - fixed issue with flashing white on load on newspaper theme
- better compatibility with themes that do not have wp booster framework
- Newsmag loads fonts in a bundle now
3.0 - better visual composer support
2.8 - Newsmag support added :)
2.7 - fixed ie 9 10 11 window resize bug
2.6 - fixed rendering bug on the loading of the page
2.5 - code improvements, newspaper 4 compatibility
- makes most of the javascript files use defer parsing
- better compatibility with revolution slider
2.4 - updated jquery version
- support for https
2.3 - fixed warnings when trying to move javascript files that are not registered
*/
define('TD_SPEED_BOOSTER' , 'v3.2');
class td_speed_booster {
var $styles_for_footer = array(); // here we keep all the stylesheets IDs that we want to move to the footer
var $is_ie = false; // if the browser is detected as IE, treat it differently
var $async_js_scripts = array(
'contact-form-7',
'bbpress',
'woocommerce',
'site',
'devicepx',
'js_composer_front'
);
var $td_theme_name = '';
var $td_theme_version = '';
var $td_deploy_mode = '';
function __construct() {
add_action('td_wp_booster_loaded', array($this, 'td_wp_booster_loaded'));
}
function td_wp_booster_loaded() {
// read the theme version and name if defined
if (defined('TD_THEME_VERSION') and defined('TD_THEME_NAME') and defined('TD_DEPLOY_MODE')) {
$this->td_theme_version = TD_THEME_VERSION;
$this->td_theme_name = TD_THEME_NAME;
$this->td_deploy_mode = TD_DEPLOY_MODE;
} else {
return;
}
// detect IE 8 9 10 11
if (!empty($_SERVER['HTTP_USER_AGENT']) and (preg_match('~MSIE|Internet Explorer~i', $_SERVER['HTTP_USER_AGENT']) || (strpos($_SERVER['HTTP_USER_AGENT'], 'Trident/7.0; rv:11.0') !== false))) {
$this->is_ie = true;
}
// add hooks
add_action('wp_enqueue_scripts', array($this, 'enqueue_scripts_hook'), 1002); // 1002 priority - because visual composer has 1000 and we use 1001 in the wp010 theme
add_action('wp_footer', array($this, 'wp_footer_hook'), 15);
if ($this->is_ie === false) {
add_action('wp_head', array($this, 'wp_head_hook'), 15);
}
}
function enqueue_scripts_hook() {
global $wp_scripts;
//detect revmin - revolution slider and do not move jquery
if( !is_admin() and !isset($wp_scripts->registered['revmin'])){
if (is_ssl()) {
$td_protocol = 'https';
} else {
$td_protocol = 'http';
}
wp_deregister_script('jquery');
wp_register_script('jquery', ($td_protocol . '://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js'), true, '1.11.1', true);
wp_enqueue_script('jquery');
}
if ($this->td_theme_name == 'Newsmag') {
/* wp 010*/
$this->move_style_to_footer('js_composer_front');
$this->move_style_to_footer('js_composer_custom_css');
}
// Newsmag dosn't move the css to the bottom as such, bbpress should stay at the top
if ($this->td_theme_name != 'Newsmag') {
$this->move_style_to_footer('bbp-default-bbpress'); //bpress old
$this->move_style_to_footer('bbp-default'); //bpress
$this->move_style_to_footer('google-font-rest');
$this->move_style_to_footer('contact-form-7');
$this->move_style_to_footer('genericons');
$this->move_style_to_footer('jetpack');
$this->move_style_to_footer('jetpack-widgets');
$this->move_style_to_footer('jetpack-subscriptions');
$this->move_style_to_footer('sharing-css');
}
/**
* Move the style only on newspaper
* @todo move the style also on newsmag after we fix all the issues
*/
if ($this->is_ie === false and $this->td_theme_name == 'Newspaper') {
$this->move_style_to_footer('td-bootstrap');
$this->move_style_to_footer('td-theme'); //this is the main style of the theme, it depends on td-bootstrap to load
}
$this->move_style_to_footer('woocommerce_frontend_styles');
//jetpack lost styles
$this->move_style_to_footer('jetpack-subscriptions');
$this->move_style_to_footer('jetpack-widgets');
$this->move_style_to_footer('genericons');
$this->move_style_to_footer('jetpack');
$this->move_style_to_footer('td-theme');
$this->move_style_to_footer('sharing-css');
/**
* move javascript to footer
*/
$this->move_js_to_footer('themepunchtools');
$this->move_js_to_footer('revmin');
// remove strange custom.css file loaded by visual composer
wp_deregister_style('js_composer_custom_css');
// replace comment-reply.min.js with inline version
}
function wp_footer_hook() {
//get the theme version for style
$current_theme_version = $this->td_theme_version;
//on demo mode, autogenerate version hourly + day
if ($this->td_deploy_mode == 'demo') {
$current_theme_version = date('jG');
}
foreach ($this->styles_for_footer as $style_id => $style_src) {
echo "<link rel='stylesheet' id='" . $style_id . "-css' href='" . $style_src . "?ver=" . $current_theme_version . "' type='text/css' media='all' />\n";
}
}
function wp_head_hook() {
if ($this->td_theme_name == 'Newspaper') {
echo '<style>body {visibility:hidden;}</style>';
}
}
function move_style_to_footer($style_id) {
global $wp_styles;
if (!empty($wp_styles->registered[$style_id]) and !empty($wp_styles->registered[$style_id]->src)) {
$this->styles_for_footer[$style_id] = $wp_styles->registered[$style_id]->src;
wp_deregister_style($style_id);
}
}
function move_js_to_footer($js_id) {
global $wp_scripts;
if (isset($wp_scripts->registered[$js_id])) {
wp_enqueue_script($js_id, ($wp_scripts->registered[$js_id]->src), '', $wp_scripts->registered[$js_id]->ver, true);
}
}
function async_js_hook($url) {
//check to see if we have js
if (strpos( $url, '.js' ) === false) {
return $url;
}
if ($this->strpos_array($url, $this->async_js_scripts) === false) {
return $url;
} else {
return "$url' defer='defer";
}
}
private function strpos_array($haystack_string, $needle_array, $offset=0) {
foreach($needle_array as $query) {
if(strpos($haystack_string, $query, $offset) !== false) {
return true; // stop on first true result
}
}
return false;
}
}
new td_speed_booster();
-
This reply was modified 11 years by
cem.
Hello,
I would like to update newspaper 4 to 6 but i can’t add more inline ads in my post. can you help me?
I need insert one ads with inline ads at 2 paragraph y another ads inline adns at 5 paragraph.
I need do this. Can you add another inline ads in theme panel ???
And when i show de responsive versión with template 11 with videos the ads don’t show. My site need ads 🙂
Thanks
Hi,
Please check our documentation – https://forum.tagdiv.com/page-speed-guide/ for more info on how to customize your site’s page speed and other matters and also you can follow and use all instructions provided in these treads:
* https://forum.tagdiv.com/topic/tutorial-chriss-custom-optimizations-for-functions-php-etc/
* https://forum.tagdiv.com/topic/pagespeed/
Thanks!
Some traffic not caught due to anonymous browsing; some things not tracked due to duplicate visitors vs unique visits; some duplication from same IPs (e.g., AOL, cable company) may not be counted twice even though two visitors (some systems look for some other data, some just count two people using same IP as same person, not unique).
Google never gets all visits as javascript doesn’t work all browsers, alt image pixel may be blocked by adblocker software, etc.
AdSense may combine all ads served (2 ads per page 10,000 visits = 20,000 impressions) dpending on what you look at.
We have found using something like PIWIK (open source) running on server is middle ground. if you have dedicated server, worth looking at 🙂
Or, go by AWSTATS which is counting content actually SERVED by the hardware/software and will be more accurate. If your website serves 10,000 pages – then that is how many pages got served. Period.
Hi guys,
(contextual: no dev skills whatsoever, basic wordpress knowledge as you will probably find out by my question)
Probably (it there is a problem) this is not Newspaper/TagDiv related but maybe you can help me finding the best tool/solution to sort this out.
I’ve read plenty about the issue: differences between server (Awstats) / Analytics / Adsense traffic. I know enough to expect different traffic figures between the three based on the major issues in hand (server stats doesn’t comply with the tighter GAnalytics rules and Adsense might not be serving all my pageviews.
Nevertheless i find the diference in figures much bigger than the average difference ratios mentioned online so i was wondering if you would suggest any audit tool/service in order for me to check the health of the analytics tags on my newspaper powered website. I’ve just registred to PowermyAnalytics.com but i was wondering if is there another way for a Newspaper theme user to check tags (and any other relevant issues that might be affecting these numbers).
Sharing the figures:
Website: http://www.goalpoint.pt
AWstats traffic for May15 (visualized traffic):
19,014 unique users 34,403 sessions 583,123 pageviews
Analytics traffic (same period):
15,719 Un. Users 21,556 sessions 106,217 pageviews
Adsense traffic (same period): 39,502 pageviews
Hope anyone can advice me on this, thanks in advance,
Pedro Ferreira
GoalPoint
Sorry, I didn’t realise it was so simple as upload an image and paste the path there. Perhaps it would be a nice sugestion to the next update: change the sentence on the Ads panel so that people get right away that one can paste there the image url or an adsense code. Another good sugestion I guess would be to have an upload buttom there in order to upload images.
Thanks for the atention! 🙂
Hi!
My costumer does not want to use Google Ads but own ads created with images. In other words, he will sell the ads localy and then produce them as JPG files and upload them into the website.
The question is: how do I turn the Header ad into an image ad?
Hi, the ad on the sidebar is not shown while the header ad is ok.
The two ads works fine on an another theme.
The title is shown with a blank space corresponding to the ad size.
So…?
I have a try with the footer ad…not shown also and no title.
Hi,
Theme ad system was designed to render ad sense code. For non adsense we recommend to use these divs or something similar and add a fixed width for your banners for different screen size – https://forum.tagdiv.com/ads/
Also you can use text block to render your ads or try to use a plugin like Ad Rotate or Simple Ads Manager that many users are using.
On first link where your ad is displayed – 580x400 – you use it in article inline spot from Theme Panel – http://screencast.com/t/6i8Skm3G6wCg but on the other article you use it in div(directly in the post content I guess) and you have an inline css – http://screencast.com/t/2QBtyhc1 – http://screencast.com/t/R2oY6NudC
Thanks!
Hi there!
I have 2 different sites, both using Newspaper theme. Both sites retrieved ads from a revive ad server.
The theme ad settings are identical, however on one of the sites, the ad is resized on the other its not.
(Article inline)
Correctly rendered (source 580×400 px ad)
http://www.fluefiskesiden.no/artikler/praktisk-fiske/skogsvannet-i-juli-og-august/
Incorrectly rendered (source 580×400 px ad)
http://www.hooked.no/artikler/tommy-vant-verdens-mest-prestisjefylte-speykonkurranse
Any ideas?
Bernt
Can’t seem to figure out how to make a Custom Ad Box display Google AdSense code for a Super Leaderboard ad. This code works when pasted into a regular text box in Visual Composer and displays the correct size (970×90):
<script async src=”//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js”></script>
<!– Super Leaderboard –>
<ins class=”adsbygoogle”
style=”display:inline-block;width:970px;height:90px”
data-ad-client=”ca-pub-6690019914503558″
data-ad-slot=”9551254263″></ins>
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>
However when it’s put in a Custom Ad Box, only ads that are 300×250 will be delivered. Please see a test page at http://www.weddinc.com/?page_id=362. Text box with code is below the slider, Custom Ad Box with same code is below the Content Block. Sorry to bother you, really tried to work it out myself… Happy to provide login if helpful. Thanks!
Hi,
The smartlists content isn’t supposed to show the ads as its handled different as in case the post’s content isn’t using smartlists so this is the right behavior.
You can use ad spot’s shortcodes to place ads inside smart lists content if you like. We also have this on our requests lists and we will consider trying another approach on this in future updates.
Thanks!
Hi,
Please try to add another size for ads – http://screencast.com/t/KeTjPa0HJJg also in this file – http://screencast.com/t/xCUmZ6oBy5ep and it should appear in Theme Panel > Ads section to control it.
Thanks!
I need to add a horizontal line below the Heading which would dieerentiate bewteen teh ads and the heading