Jump to content

gerald

Members
  • Posts

    18
  • Joined

  • Last visited

Posts posted by gerald

  1. Thanks Jan, for your quick reply. I had a small configuration error in the backend, which is why htmx did not work immediately. I use htmx for the first time, so I looked for the error in the wrong place 😔 Thank you for the quick response time. It's always inspiring to see how helpful everyone is here!

    • Like 1
  2. Has anybody a simple example, how htmx works in the frontend, please, e.g. with form:

    <input type="text" name="q"
        hx-get="/trigger_delay"
        hx-trigger="keyup changed delay:500ms"
        hx-target="#search-results"
        placeholder="Search..."
    >
    <div id="search-results"></div>

    Thanks!!

  3. Thanks, maxf5,

    hmm, I feel like a bloody beginner, but it just does´nt work. Here my _main.php:

        <div id="result">Ajax</div>
    
        <script type="text/javascript">
                $('#result').click(function () {
                    var ajaxUrl = "<?= urls()->templates ?>ajax.inc";
                    $.ajax({
                        type: "GET",
                        url: ajaxUrl,
                        success : function(data){
                            var markup = $(data).find('#result');
                            $('#result').html(markup);
                        }
                    });
                });
        </script>

    ajax.inc only with a simple string for testing:

    <?php namespace ProcessWire; ?>
    OK, Ajax works!

     

  4. In my frontend I would like to implement a small AJAX-solution, but it does´nt work. For example:

    template/js/ajax.js: contains jquery-ajax-snippet with click-function like this: $.post('ajax.inc', function(e) {});
    template/ajax.inc: contains db-query with HTML-output
    template/home.php: contains div-element for the ajax-response, e.g. <div id='result'>...ajax-response...</div>

    It seems, PW does´nt allow database-requests via AJAX (jquery). I know the post from Ryan "How to work with AJAX driven content in ProcessWire". But this solution requires a completely new template-concept. I only need a simple solution for a small ajax-db-request.

    Thanks to all

  5. Hello Ryan! First, my great thanks for processwire. Since I know it, it´s the purest joy to develop websites. Thank you very much.

    Now that I've designed some business websites while this question has arisen: In the tree view of the backend you use the title tag to display the path information of a page, for example "/about/". This feature is very helpful to get this information very quickly. Would it be possible to make the same effect with field names? Some fields get a different name and it is a bit cumbersome, to get the fieldname used in the database. Now there is even a hover effect with field names, but nothing is displayed.

    Thanks in advance for your answer.

  6. Hi, I´ve uploadet my files with all neccessary settings (chmod dir:755/files:644, assets files & dir 755, mod_rewrite=On, cache empty). The root-site works, but all children-sites respond with: "The server encountered an internal error or misconfiguration and was unable to complete your request.". It seems, mod_rewrite ist OFF, but I´ve checked it more than one time - it is ON! I also switched the options +FollowSymLinks / +SymLinksifOwnerMatch in .htaccess - nothing!
    Any ideas, please?
    Server PHP Version: 5.3.19.
    Thank you so much

  7. Hi everybody, I have a main menu item with children. By clicking on the main menu item, automatically the first child should be displayed. How to solve this problem? If a similar question has already been answered - sorry, could´nt find it. Thanks very much.

    Gerald, Austria

×
×
  • Create New...