<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Javascript - ThemesPress</title>
	<atom:link href="https://themespress.ca/en/sujets/javascript-coding/feed/" rel="self" type="application/rss+xml" />
	<link>https://themespress.ca/en/</link>
	<description>Experts en développement d’API, plugins et intégrations WordPress.</description>
	<lastBuildDate>Sat, 01 Oct 2022 19:04:54 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.1.5</generator>

<image>
	<url>https://themespress.ca/wp-content/uploads/2020/10/cropped-Favicon-Themepress.ca_-32x32.png</url>
	<title>Javascript - ThemesPress</title>
	<link>https://themespress.ca/en/</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Using the wp_enqueue_style Bootstrap Function</title>
		<link>https://themespress.ca/en/using-wp-enqueue-style/</link>
					<comments>https://themespress.ca/en/using-wp-enqueue-style/#respond</comments>
		
		<dc:creator><![CDATA[Daniel]]></dc:creator>
		<pubDate>Mon, 11 Sep 2017 14:59:19 +0000</pubDate>
				<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[Javascript]]></category>
		<category><![CDATA[Plugins]]></category>
		<guid isPermaLink="false">https://themespress.ca/?p=5177</guid>

					<description><![CDATA[]]></description>
										<content:encoded><![CDATA[<div class="wpb-content-wrapper"><div class="vc_row wpb_row vc_row-fluid"><div class="wpb_column vc_column_container vc_col-sm-12"><div class="vc_column-inner"><div class="wpb_wrapper">
	<div class="wpb_text_column wpb_content_element" >
		<div class="wpb_wrapper">
			<p>With this tutorial we will use the Bootstrap Stylesheet in one or multiple pages of our plugin; such as Settings, sub menus, etc&#8230;</p>
<p>This will help avoid CSS conflicts or force other CSS styling from other WordPress plugins. Here&#8217;s a quick trick to use <strong>wp_enqueue_style</strong> in the <strong>admin_enqueue_scripts</strong> hook.</p>
<p>This condition only works with a page ID. So if for example you have sub-pages in your plugin, we will develop it under it:</p>
<p>[gridzy id=&#8221;5&#8243;]</p>

		</div>
	</div>
<div id="ts-enlighterjs-container-7217258" class="ts-enlighterjs-container-single-enabled  " style="width: 100%;  margin-top: 0px; margin-bottom: 0px;" data-enlighter-doubleclick="true" data-enlighter-windowbutton="true" data-enlighter-windowtext="New Window" data-enlighter-rawbutton="true" data-enlighter-rawtext="RAW Code" data-enlighter-infobutton="false" data-enlighter-infotext="EnlighterJS" data-enlighter-indent="2"><pre id="ts-enlighterjs-pre-7217258" class="" style="white-space: pre-wrap; height: 100%; margin: 0; padding: 0;" data-enlighter-language="standard" data-enlighter-theme="enlighter" data-enlighter-group="" data-enlighter-title="" data-enlighter-linenumbers="true" data-enlighter-lineoffset="1" data-enlighter-highlight="">function themeplifyenqueuebootstrap()
{
    //replace themeplify with your slug page ID
    if(($_GET[&#039;page&#039;] == &#039;themeplify&#039;) || ($_GET[&#039;page&#039;] == &#039;autreslugid&#039;) || ($_GET[&#039;page&#039;] == &#039;encoreunautreslugid&#039;) ) {
        wp_enqueue_style(&#039;bootstrap.min&#039;, &#039;https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css&#039;);
    }
}

add_action(&#039;admin_enqueue_scripts&#039;, &#039;themeplifyenqueuebootstrap&#039;);</pre></div>
	<div class="wpb_text_column wpb_content_element" >
		<div class="wpb_wrapper">
			<p>With multiple GET pages &#8230;</p>

		</div>
	</div>
<div id="ts-enlighterjs-container-3488646" class="ts-enlighterjs-container-single-enabled  " style="width: 100%;  margin-top: 0px; margin-bottom: 0px;" data-enlighter-doubleclick="true" data-enlighter-windowbutton="true" data-enlighter-windowtext="New Window" data-enlighter-rawbutton="true" data-enlighter-rawtext="RAW Code" data-enlighter-infobutton="false" data-enlighter-infotext="EnlighterJS" data-enlighter-indent="2"><pre id="ts-enlighterjs-pre-3488646" class="" style="white-space: pre-wrap; height: 100%; margin: 0; padding: 0;" data-enlighter-language="standard" data-enlighter-theme="enlighter" data-enlighter-group="" data-enlighter-title="" data-enlighter-linenumbers="true" data-enlighter-lineoffset="1" data-enlighter-highlight="">function themeplifyenqueuebootstrap()
{
    //replace themeplify with your slug page ID
    if(($_GET[&#039;page&#039;] == &#039;themeplify&#039;) || ($_GET[&#039;page&#039;] == &#039;autreslugid&#039;) || ($_GET[&#039;page&#039;] == &#039;encoreunautreslugid&#039;) ) {
        wp_enqueue_style(&#039;bootstrap.min&#039;, &#039;https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css&#039;);
    }
}

add_action(&#039;admin_enqueue_scripts&#039;, &#039;themeplifyenqueuebootstrap&#039;);</pre></div>
	<div class="wpb_text_column wpb_content_element" >
		<div class="wpb_wrapper">
			<p>You can also add another function or class for the Javascripts Bootstrap by using the same conditions. You allow your plugin to have an independant Javascript and/or CSS stylesheet.</p>

		</div>
	</div>
</div></div></div></div>
</div><p>The post <a href="https://themespress.ca/en/using-wp-enqueue-style/">Using the wp_enqueue_style Bootstrap Function</a> first appeared on <a href="https://themespress.ca/en/">ThemesPress</a>.</p>]]></content:encoded>
					
					<wfw:commentRss>https://themespress.ca/en/using-wp-enqueue-style/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
