Days
Hours
Minutes
Seconds

Super Black Friday Sale!

0
No products in the cart.

Forum Replies Created

Viewing 15 posts - 706 through 720 (of 741 total)
  • Author
    Posts
  • in reply to: Why is Magento so slow? #9852
    blankabctest483
    Member

    it will also come down to functionality versus performance.

    Raw performance is gained using nginx, php-fpm, memcached, apc and a proper designed server.

    Functionality like plesk and magento performance could be managed by taking the entire infrastructure in perspective when designing a magento performance cloud.

    in reply to: Recommended way to embed PDF in HTML? #9321
    blankabctest483
    Member

    Scribd no longer require you to host your documents on their server. If you create an account with them so you get a publisher ID. It only takes a few lines of JavaScript code to load up PDF files stored on your own server.

    For more details, see Developer Tools.

    in reply to: How To Include CSS and jQuery in my WordPress plugin? #10003
    blankabctest483
    Member

    See http://codex.wordpress.org/Function_Reference/wp_enqueue_script

    Example

    <?php
    function my_init_method() {
        wp_deregister_script( 'jquery' );
        wp_register_script( 'jquery', 'http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js');
    }    
    
    add_action('init', 'my_init_method');
    ?> 
    
    in reply to: How To Include CSS and jQuery in my WordPress plugin? #10008
    blankabctest483
    Member

    For styles wp_register_style( 'namespace', 'http://locationofcss.com/mycss.css' );

    Then use: wp_enqueue_style('namespace'); wherever you want the css to load.

    Scripts are as above but the quicker way for loading jquery is just to use enqueue loaded in an init for the page you want it to load on: wp_enqueue_script('jquery');

    Unless of course you want to use the google repository for jquery.

    You can also conditionally load the jquery library that your script is dependent on:

    wp_enqueue_script('namespaceformyscript', 'http://locationofscript.com/myscript.js', array('jquery'));

    Update Sept. 2017

    I wrote this answer a while ago. I should clarify that the best place to enqueue your scripts and styles is within the wp_enqueue_scripts hook. So for example:

    add_action('wp_enqueue_scripts', 'callback_for_setting_up_scripts');
    function callback_for_setting_up_scripts() {
        wp_register_style( 'namespace', 'http://locationofcss.com/mycss.css' );
        wp_enqueue_style( 'namespace' );
        wp_enqueue_script( 'namespaceformyscript', 'http://locationofscript.com/myscript.js', array( 'jquery' ) );
    }
    

    The wp_enqueue_scripts action will set things up for the “frontend”. You can use the admin_enqueue_scripts action for the backend (anywhere within wp-admin) and the login_enqueue_scripts action for the login page.

    in reply to: Why is Magento so slow? #9857
    blankabctest483
    Member

    I’m more involved in the managed server optimization in my company but I may have a few tips for you. First, you can look at the code more closely using the code tracing feature of Zend server. It will allow you to see where and when the things get dirty.

    I totally share benlumley’s consideration regarding the cache. Most of the sites we host doesn’t even have the block caching enable. This cache has to be explicitly called and not “assumed”. So if you code hasn’t yet took part of this mechanism, it’s something you definitely want to try. If you have a EE version, you can get the Full page up in order to get the best of the beast.

    A reverse proxy will also help a lot. It’ll cache the static ressources, significantly lowering the pressure on the php interpretation stack of your front servers.

    Don’t forget to write the sessions & Magento cache to a RAM disk. This will also definitely get you to another level of performances.

    There’s still a lot to be said here but I’m running out of time. You have to know that a good site, well coded in a 1.4.1 CE version, running on a 2×5650 Xeon + 16 GB RAM server and having a Rproxy on top can take up to 50 000 unique visitors a day with smooth pages to everybody.

    in reply to: Why is Magento so slow? #9856
    blankabctest483
    Member

    Switching from Apache to LiteSpeed helped us a lot. In addition to: Editing MySQL’s settings, installing Fooman Speedster (module to compress/combine js and css files), and installing APC. Magento has also posted a white paper on how to get the best performance out of the enterprise edition, but it is equally applicable to the other versions: http://www.magentocommerce.com/whitepaper/

    in reply to: JQuery – $ is not defined #9734
    blankabctest483
    Member

    I got the same error message when I misspelled the jQuery reference and instead of type="text/javascript" I typed “…javascirpt”. 😉

    in reply to: Magento products will not show in category #9881
    blankabctest483
    Member

    I would also add: make sure for the category under the Display Settings tab, the Display Mode is set to “Products Only” or “Static blocks and products”. If this is set to “Static block only”, the products will not display for the category.

    in reply to: Path to WordPress Template Directory inside jQuery? #9547
    blankabctest483
    Member

    You could create a Javascript snippet that saves the template dir in a variable, and use this later:

    <script>
    var templateDir = "<?php bloginfo('template_directory') ?>";
    </script>
    
    in reply to: Why is Magento so slow? #9855
    blankabctest483
    Member

    When I first installed I had pages that were taking 30 seconds to load. My server was not maxed out in ram or processor, so I didn’t know what to do. Looking at firebug’s net panel it was loading about 100 files per page, and each one took a long time to connect. After installing fooman speedster and the gzip in the htaccess loads times were down to 3 seconds, like they had been on other shopping carts on my server.

    in reply to: Why is Magento so slow? #9854
    blankabctest483
    Member

    Magento is very slow because the database design is not very good. The code is a mess and very hard to update and optimize. So all optimizations are done via cache instead of code.

    On the other hand. It is a webshop with a lot of tools. So if you need a flexible webshop just buy a very powerfull server and you will be ok.

    in reply to: Why is Magento so slow? #9853
    blankabctest483
    Member

    There are many reasons why your Magento shopping cart could be running slow but no excuses for there is a variety of ways to eleviate the problem and make it pretty darn fast. Enabling Gzip by modifying your htaccess file is a start. You can also install the fooman speedster extension. The type of server used also will determine the speed of your store. More tips and a better explanation here http://www.interactone.com/how-to-speed-up-magento/

    in reply to: Magento products will not show in category #9884
    blankabctest483
    Member

    The checklist for whether items are in stock follows. Some will seem stupid until the first time you spend an hour trying to figure this problem out:

    1. The products must be Visible in Catalog.
    2. The products must be Enabled.
    3. Product must have a stock Quantity.
    4. The product must be set to In Stock.
    5. If the product is set not to track stock, it still has to have a stock Quantity and be set to In Stock.
    6. The product must be assigned to the target Category.
    7. If using multi-website mode (or if you imported the products through Data Flow), the products must be assigned to the target Website.
    8. You must refresh your Cache / Indices, just to make sure.
    in reply to: Magento products will not show in category #9878
    blankabctest483
    Member

    Check your product stock management options, in the default config items out of stock are not being displayed.

    in reply to: Selecting element by data attribute with jQuery #9354
    blankabctest483
    Member
    $('*[data-customerID="22"]');
    

    You should be able to omit the *, but if I recall correctly, depending on which jQuery version you’re using, this might give faulty results.

    Note that for compatibility with the Selectors API (document.querySelector{,all}), the quotes around the attribute value (22) may not be omitted in this case.

    Also, if you work with data attributes a lot in your jQuery scripts, you might want to consider using the HTML5 custom data attributes plugin. This allows you to write even more readable code by using .dataAttr('foo'), and results in a smaller file size after minification (compared to using .attr('data-foo')).

Viewing 15 posts - 706 through 720 (of 741 total)