Jump to content

totoff

Members
  • Posts

    495
  • Joined

  • Last visited

  • Days Won

    4

Posts posted by totoff

  1. Hi all,

    my new website is online but not yet finished. Though it looks good, I have plans for several improvements on both, coding and design. I wonder how others develop on websites that are live? What is your workflow? Do you have a clone and sync your changes back to live? Do you put the site offline for the times you develop on it? Or don't you care at all and just work on the live site?

    Curious to learn how others deal with this task.

    Thanks!

  2. Hi all,

    it has taken ages, but finally I managed to relaunch my own studio website :-)www.christophlieck.com

    The site used to be a desktop only site running on Contao and is now both mobile friendly and based on a real CMS (PW btw). I decided not to change the site design much to much as I still like it (it was first designed back in 2007) but made it a bit bigger (screenshot of old site with 800px width attached, new size is  960 px max.).

    There is still a lot of work to do (don't mind the blog section!) - but it's online!

    Modules:

    • ProCache
    • Email Obfuscator
    • Image Extra
    • Markup Sitemap XML
    • Page List Show Page Id
    • Redirects
    • Batcher
    • Database Backups
    • Image Tags

    I still don't like WYSIWYG-editors, so no CKEditor involved. I prefer Markdown - and PW supports it!  ^-^

    The responsive grid is based on Gridset, which I can strongly recommend as both, extremely flexible and time saving.

    Comments welcome, many thanks!

    post-625-0-54558700-1448275164_thumb.png

    • Like 8
  3. Hello Horst,

    unfortunately this is not what I meant. The page tree in the admin needs to remain as it is (as it makes for the desktop navigation). I need a custom order ("sorting") only for the mobile navigation.

    In other words: I need to render the pages in a custom order different to what I have in the admin.

    Difficult to explain in English. Hope one can get it ...

  4. Hi all,

    I wonder if PW allows for a custom sort order of pages? I would like to render my page tree custom sorted for a mobile menu, e.g. not in "reverse sort order" or "sorted by date" and so on but completely customized.

    My current page tree in the admin looks as follows (numbers are page ids):

    /

    |- page 1006

    |- page 1058

    |- page 1062

    But for my mobile menu I try to render the following order:

    /

    |- 1062

    |- 1006

    |- 1058

    $entries = $pages->get("id=1|1006|1058|1062, sort=??");
    

    Any ideas how to achieve this?

    Many thanks!

  5. Hi Forum,

    I need to secure some downloads with a simple login form. As login tasks are new to me I try to adapt the code from this forum post for my purposes. This is where I am so far:

    A page with input field type "password" (name "password").

    This code:

    <?php password protected areaif ($page->password) {	$pass = $page->password;	if ($input->post->pass != $pass) {    	echo "$page->body" . file_get_contents("./_login-form.inc"); // not logged in? get input form	} else {    	foreach ($page->downloads as $file) {    		echo "<h2>Sie sind eingeloggt</h2>";			echo "<ul>" .			"<li class='plain'><i class='fa fa-download'></i><a href='$file->url';?> $file->description</a></li>" .			"</ul>";			} // foreach	} // $input->post} //$page->password?>

    And for _login-form.inc

    <form method="post" action="./" accept-charset="UTF-8">    <input type="password" id="pass" name="pass" placeholder="" />    <button type="submit" name="submit" class="btn btn-success btn-block">Login</button></form>

    Unfortunately the conditional always returns false even if the correct password has been entered into the form. This is the first time I'm using fieldtype password, thus I don't know how to check for the correct password entered (I understand the value is stored encrypted but that's all I know).

    Any help is much appreciated.

    Thanks!

  6. SFTP/Sublime is my weapon of choice since it came out. Has replaced Filezilla, Cyberduck et al. Can't think of anything else. Regarding Forklift, imho it's a very poor clone of Total Commander for Windows and it doesn't seem to be maintained anymore (no update since ages).

  7. Hi all,

    I need to loop over several images with an ordinary foreach - nothing fancy. However, each image needs to have a unique css class name attached. Here is a simplified example:

    <ul>
    	<li><img class='mac' src='#'</li>
    	<li><img class='ipad' src='#'</li>
    	<li><img class='ipod' src='#'</li>
    </ul>
    

    and so on.

    My array of images will be a collection from several pages. So the information about the required class needs to be "attached" to the image somehow. Sure I could use the description field for that, but that's kind of a hack I would like to avoid for the sake of unexperienced editors.

    My PW skills got a bit rusty the last time. Maybe an easy way to achieve that as been already introduced into the core and I missed it. Apologies in advance if this is a silly question than ...

    Ideas welcome! Thanks.

  8. Hi Forum,

    I recently had a chat with a friend who was introduced to PW by me. He said: "brilliant cms, poor documentation." His comment makes me think about the cheatsheet: While we see new API methods introduced at a very fast pace, the cheatsheet doesn't seem to keep up. That's sad, because it's such a good resource.

    So, how can I (as a user with very limited PHP skills) help to update the cheatsheet? Is somebody skilled willing to team up with me - as kind of a supervisor - for the update tasks? Or are there any plans on behalf of the team to update the cheatsheet?

    Thanks!

    • Like 10
  9. Hi diogo,

    unfortunately I get a notice with your module:

    Notice: Use of undefined constant field - assumed 'field' in *** on line 44

    This happens if image referer (markdown) are entered into the textarea, not before. The images render fine nevertheless.

    I'm on 2.6.1 in debug mode.

    EDIT:

    unfortunately it also cuts off parts of the html code (namely the "d" in my first div). I'm mixing html and markdown.

  10. Hi and welcome to pw,

    I don't think the wiki is actively maintained though it was still online a few days ago. So it's a bit weird, that it is down today. However, there are some other resources you may find helpful:

    https://processwire-recipes.com/

    http://www.flamingruby.com/blog/

    And this tutorial section of the forum of course. If you have more specific questions the fine folks from the community are always here to answer.

    • Like 2
  11. Getting back to this topic may I ask if there are any plans to update the cheatsheet in near future? Or is it discontinued? The cheatsheet is such a valuable resource. I would be glad to assist in updating it but I'm afraid my understanding of the API isn't good enough.

    Thanks for keeping us informed.

    • Like 3
  12. Hi all,

    I'm having some trouble to get $image->size() working properly inside a function. I have a function that accepts three arguments:

    function renderSlides($sites = '', $field = "", $size = "")
    

    Later on inside the function I would like to use this argument for cropping my images:

    $slideimage = $slideimage->size($size);
    

    Therefore I set $size in my template:

    $size = "690,425";
    

    If I check with var_dump(func_get_args()); it confirms I have a string:

    var_dump(func_get_args(2));
    [2]=> string(7) "690,425"
    

    Nevertheless if I render the page, I get a PHP warning

    Warning: Missing argument 2 for Pageimage::size()
    

    and the image doesn't get cropped/sized properly.

    Apologies in advance if this is a dumb question for a PHP pro, but what am I doing wrong here?

    Thanks!

  13. Hi all,

    apologies, re-reading Gerrits blog post mentioned above it indeed doesn't say this is a PW project. I remembered the blog-post wrong. Sorry for this.

  14. I'm afraid technical arguments won't count pretty much. From my experience it's references that matter. I would show them off the most prestigious sites I could find in the showcase section. The Canton site mentioned above is a very good start in this respect.

    If it comes down to a more in depth discussion I would point out the following:

    • PW is plain PHP in a way. No template language etc. Every PHP developer may still maintain it even if development is discontinued
    • easy straightforward admin, no expensive tutorials etc. required for editors
    • best choice for managing large amounts of structured data as shown in the skyscraper profile (if this matters for your client of course). Again this makes up for an easy to use admin (single point of entry for data etc.)
    • low development and maintenance cost thanks to straightforward system architecture

    If this all doesn't convince them, I recommend a WP install with a ton of rubbish plugins and a good maintenance contract for you - kind of a revenge and after-sales-satisfaction (for you, not for them)  >:D

    • Like 3
  15. Craig, alan,

    thanks, the problem persists in incognito mode. Got logged out after switching the screen resolution in Chrome Dev Tools. Very weird.

    Checking the user agent with javascript:alert(navigator.userAgent) doesn't indicates anything to be wrong though it might be that extensions interfere (Google maybe or Web developer tools extension).

    I'm clueless :-(

×
×
  • Create New...