Jump to content

Marty Walker

Members
  • Posts

    629
  • Joined

  • Last visited

  • Days Won

    3

Posts posted by Marty Walker

  1. Hi,

    I've got a problem with trying to edit a hanna code. I can see the list of codes I've setup and I can create a new one but I'm not able to edit it after I've created it. I had this problem with the final 2.4 release but I thought an update to the most recent dev build (2.4.7) might fix it but, no. There's no browser errors at all. Reinstalled it, still no.

    My server setup is: PHP 5.4.25 & MySQL 5.1.73-cll

    Any thoughts?

  2. Ohh I just got an idea for a module. What if you have a gallery type page you upload the images as usual to an images field. Then when saving the page there would be children created for each image and the ones removed from the gallery page. This would be very simple few lines of code.

    Sorry to hijack your thread. :)

    Nothing against the method to have one images field you store a gallery. If theres no metadata needed with no multilang and so on it is a pretty good and simple way to a simple gallery. I use it myself too.

    Go on then! :) Currently I'd use Batcher or CSV Import to do that. You way sounds much quicker.

    • Like 2
  3. @PhotoWebMax Short-answer, yes indeedy.

    I'm going to reference my own (very basic) photography site as an example - there are plenty of others in the gallery too. I'll probably redo it at some point to suit what I'm doing - less structure and more style categories.

    You can, of course, structure it how you like. There's plenty of people here to help and guide you. Looking forward to seeing what you come up with.

  4. Yay! This 1-step adding of pages makes complete sense to me and it's a nice addition. I've been given a few confused looks from clients when I show them the "two-step". In 99.9% of cases when my lot add a page the URL is going to match the title.

    • Like 1
  5. Does anyone why I'm getting this erro? I'm saving a page that has a markdown field. If I change anything in that field I get this:  

    SQLSTATE[42000]: Syntax error or access violation: 1066 Not unique table/alias: 'rootparent'
    

    The only thing that I can think of is I'm embedding some twitter markup which looks like:

    <blockquote class="twitter-tweet" lang="en"><p>texthere</p>— Jeff Selser (@jeffselser) <a href="https://twitter.com/">March 8, 2014</a></blockquote>
    <script async src="//platform.twitter.com/widgets.js" charset="utf-8"></script>
    

    I even have Content Type set to unknown. If I remove that script line it works ok but I would like to have the twitter styling.

  6. I'd just like to register some interest in getting markItUp! (or something similar that supports an interactive way for clients to use either textile or markdown) wrapped up as an inputfield.

    Perhaps those of us interested can pitch in a few bucks to get this happening?

  7. I got this from the forum here (probably Ryan) which might help.

        <?
        $showForm = true; 
        $email = $sanitizer->email($input->post->email);
        if($email) {
          $u = $users->get("email=$email"); 
          if($u->id) {
            // generate a random, temporary password
            $pass = '';
            $chars = 'abcdefghjkmnopqrstuvwxyz23456789'; // add more as you see fit
            $length = mt_rand(9,12); // password between 9 and 12 characters
            for($n = 0; $n < $length; $n++) $pass .= $chars[mt_rand(0, strlen($chars)-1)];
            $u->of(false);
            $u->tmp_pass = $pass; // populate a temporary pass to their profile
            $u->save();
            $u->of(true); 
            $message = "Your new password on the blah blah web site is: $pass\n";
            //$message .= "Please change it after you login.";
            mail($u->email, "Password reset", $message, "From: noreply@{$config->httpHost}"); 
            $page->body = "<p>An email has been dispatched to you with further instructions.</p>";
            $showForm = false;
          } else {
            $page->body = "<p>Sorry, account doesn't exist or doesn't have an email.</p>";
          }
        }
    
        if($showForm) $page->body .= "
          <h2>Reset your password</h2>
          <form action='./' method='post'>
          <label>E-Mail <input type='email' name='email'></label>
          <input type='submit' value='Submit'>
          <p class='spam-check'>Please check your spam folder in case this email doesn't appear within 10 minutes.</p>
          </form>
        ";
    
        // include the main HTML/markup template that outputs at least $page->body in an HTML document
        echo $page->body;
    
        ?>
    
    
    • Like 1
  8. I've got a wee job I will probably need some help with if the client goes ahead with it.

    I have an XML export of a hosted wordpress.com site (just posts, not pages and they don't let you have an sql file) I need moved into a PW blog tree. I technically know nothing about XML (and I'm not copy/pasting) so I'd appreciate some help with it.

    Cheers

    martin [at] smd.net.au

  9. Smarter people than me would have some git hook worked out. As I don't really use git (because I work alone [sniff]) although I am trying to learn the thing. I upload the db manually via phpmyadmin and my site files via ftp. If it's just me I can't see the point of uploading to a git repo then paying for a service to deploy it. If I was working with others on coding a site git would be the go for sure.

    • Like 4
  10. Happy yet demanding :) I can't wait to test this update.

    This Replace feature has me thinking (which I'll test soon). I know it's probably outside of the scope of what you're doing but how difficult would it be to periodically replace a page tree from one site to another? I'm thinking in terms of a site sharing a blog or news section. I know I could use Pages Web Service to show post lists but I'm thinking of shifting entire posts between sites regularly.

  11. I figured that might be the case as I hadn't logged that inc as a template at all - there was no real need to. I didn't see a message though - or maybe I missed it. I'll take a look next time I try it, which will be soon.

  12. If it helps my MAMP setup is running PHP 5.4.25

    Actually there was a one things I noticed that didn't get packaged up in the zip I exported - and that was an include I used to show my blog categories. It might just be the way I've set it up but I'll put together something for you to look at later.

×
×
  • Create New...