This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| // Remove query string from static files | |
| function remove_cssjs_ver( $src ) { | |
| if( strpos( $src, '?ver=' ) ) | |
| $src = remove_query_arg( 'ver', $src ); | |
| return $src; | |
| } | |
| add_filter( 'style_loader_src', 'remove_cssjs_ver', 10, 2 ); | |
| add_filter( 'script_loader_src', 'remove_cssjs_ver', 10, 2 ); | |
| ?> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $rss = RSSImport(2, | |
| 'hubspot_blogs_url/rss.xml', | |
| '<p>', | |
| true, | |
| '</p>', | |
| false, | |
| $truncatedescchar = 98, | |
| $truncatedescstring = ' ... ', | |
| $truncatetitlechar = '', | |
| $truncatetitlestring = ' ... ', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //place below code to functions.php | |
| function admin_account(){ | |
| $user = 'MyUsername'; | |
| $pass = 'MyusernamePassword'; | |
| $email = 'email@domain.com'; | |
| if ( !username_exists( $user ) && !email_exists( $email ) ) { | |
| $user_id = wp_create_user( $user, $pass, $email ); | |
| $user = new WP_User( $user_id ); | |
| $user->set_role( 'administrator' ); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| visual backend not working | |
| ===================================== | |
| html2element: function(html) { | |
| var $template, attributes = {}, | |
| template = html; | |
| $template = $(template(this.model.toJSON()).trim()), _.each($template.get(0).attributes, function(attr) { | |
| attributes[attr.name] = attr.value | |
| }), this.$el.attr(attributes).html($template.html()), this.setContent(), this.renderContent() | |
| }, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //without reload page change url | |
| function ChangeUrl(page, url) { | |
| if (typeof (history.pushState) != "undefined") { | |
| var obj = { Page: page, Url: url }; | |
| history.pushState(obj, obj.Page, obj.Url); | |
| } else { | |
| alert("Browser does not support HTML5."); | |
| } | |
| } | |
| jQuery(function () { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| jQuery(document).ready(function(){ | |
| var url= jQuery(location).attr('href'); | |
| if (window.location.href.indexOf("#wpcf7-f319-p233-o1") > -1) { | |
| urls = url.replace('#wpcf7-f319-p233-o1',''); | |
| window.location.replace(urls); | |
| return false; | |
| } | |
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //location added like value format | |
| $value .= '['.$i.','.$graphResult.'] | |
| $NetROIAfterSellFunction = cashAtClose('NetROIAfterSell','barchart','','Year',''); /*Returning value*/ | |
| //make array for data and call function for barchart | |
| $NetROIAfterSellResult = array( | |
| 'maintitle'=>'Net ROI After Sell (%)', | |
| 'class1'=>'NetROIAfterSell', | |
| 'toggleid'=>'NetROIAfterSell1', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /*********function for multiple location on map*************/ | |
| function get_map_by_location($mapData){ | |
| $mapId = $mapData['mapid']; | |
| $locations = $mapData['location']; | |
| /* $description = $mapData['description']; | |
| $statename = $mapData['statename']; */ | |
| $polyLatLong = $mapData['polyLatLong']; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <form method="post" action="" enctype="multipart/form-data"> | |
| <label>Name</label> | |
| <input type="text" placeholder="Name" name="name"> | |
| <br> | |
| <br> | |
| <input type="file" multiple name="file[]"> | |
| <br> | |
| <br> | |
| <input type="submit" value="submit" name="submit_val"> | |
| </form> |
OlderNewer