Jump to content

AnotherAndrew

Members
  • Posts

    168
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by AnotherAndrew

  1. Ryan, there has to be an easier way. Ok, so I created a body content image field, and when I use the tinymce editor, I call the image and it is placed in the appropriate field. BUT, I want a user to be able to click on the image to link to either another page, file, or in this case to load a video. AND, from a user standpoint it might seem a little confusing to have to type in "images" in the text editor to place an image. I think that a user would want to see that image immediately in the editor than rely on blind faith that it would appear.
  2. Ryan, thanks for the example. And this is getting me up and running. However, I just wanted to post a correction to your first example since you were missing a ")" in that code: <?php // $out is where we'll keep our output $out = ''; // $form is where we'll keep our custom login form $form = " <form action='./' method='post'> <p><label>Username <input type='text' name='user' /></label></p> <p><label>Password <input type='password' name='pass' /></label></p> <p><input type='submit' name='submit_login' value='Login' /></p> </form>"; if($user->isLoggedin()) { // user is already logged in if($input->get->logout) { // page was accessed with ?logout=1 GET variable, so log them out $session->logout(); $session->redirect('./'); } else { // tell them they are logged in and how to logout $out = "<p>You are logged in. <a href='./?logout=1'>Logout?</a></p>"; } } else if($input->post->user && $input->post->pass) { // user submitted the login form if($session->login($input->post->user, $input->post->pass)) { // user was authenticated and logged in $session->redirect('./'); // or redirect to your members-only page } else { // the login failed $out = "<p class='error'>Login failed</p>"; $out .= $form; } } else { // user arrived at login page for first time $out = $form; } include("./head.inc"); // your site header, if applicable echo $out; include("./foot.inc"); // your site footer, if applicable
  3. In reference to Concrete5: No! Don't go that way of developing commercial code. I have used C5 for awhile and in my opinion, the community support has gone downhill since they opened up to commercial interests. Now everyone just wants to make a buck. Look at their marketplace and there are fewer and fewer "free" modules/plugins/add-ons. (I might add that I am currently converting a C5 site to PW, since I find PW to be easier to understand for a client) I think that PW should go the route of Wordpress, at least in terms of their website. There are commercial wordpress solutions but they are not advertised on wordpress.org. Please keep PW truly open source and free of commercial gains.
  4. Is it possible to do this: if($user->isSuperuser()) $config->sessionExpireSeconds = 86400; else $config->sessionExpireSeconds = 23200;
  5. I wish I could but I'm broke and can't afford a new computer! Yes this seems to be a problem on older browsers. I have no problem with the latest browsers.
  6. Ok, thanks. I forgot to mention that I was using Firefox 3. This seems to be the problem.
  7. I have a file field where a user can upload videos and then link to in a text field. However, when I try to upload a large video file, say 60 megs, it does not completely upload. I am testing on MAMP and have set the upload file size and post size to 200 megs, but it is still not working. Anyone have suggestions to how this can work?
  8. Is there a way to change the session time before a user is automatically logged off? I see that PW automatically logs off an admin user after a set amount of time, but what about a new user role that I created?
  9. Ryan, that is exactly what I was looking for. Thank you. And yes I think this would be very useful for others!
  10. Ryan it would be great if you could share some tips on how to implement a custom login script. Everything that I found on the forums has been geared towards the previous build of PW. Perhaps a tutorial on how to do so would be good? Thanks for sharing PW. I love the simplicity of the system!
  11. O but wait! How can I get the description text to appear? I can put this in my template, but I want this to show in my "body" field. And I want it to be exactly where it was placed in the body field. foreach($page->body_images as $image) { $thumb = $image; echo "<ul>"; echo "<li>"; echo "<img src='{$thumb->url}' alt='{$thumb->description}' />"; echo "<p>$thumb->description</p>"; echo "</li>"; };
  12. OK, thanks, that is what I am hung up on. I will have to create another image field as suggested.
  13. I am using a file field to allow users to upload documents and images to link to in a textarea field that I have called documents. I can link to the documents, such as a pdf file, but not to an image file that has been uploaded. When I select an image from the tinymce editor, the image file does not appear. I have an image field that I can see those images but not the ones that were uploaded to the document field. And yes, I have allowed jpgs, etc. to be uploaded to the document field. I don't want to upload images to the image field since I am using this field for sidebar images. Is this a bug, am I being dumb, or is there some other way to do this?
  14. Thanks Ryan. The iframe option would definitely work, but I am having a hard time understanding what the url would be based on creating a login form as it was described earlier in this thread. Would I want to choose another url in the access tab or select show the login page?
  15. How could I redirect the page to a custom login form in a modal box overlay?
×
×
  • Create New...