Jump to content

vxda

Members
  • Posts

    169
  • Joined

  • Last visited

  • Days Won

    1

Everything posted by vxda

  1. HAHA <3 LOVE IT ! ty Soma
  2. Another question: in my form i got <input type="text" name="url"/> now in php i want to check if this is image, if it is attatch it to fieldinput image_url, but if its url to youtube or vimeo attatch it to textarea video_url. im using this plugin for vids: http://modules.processwire.com/modules/textformatter-video-embed/ Is there a way to check if the link is a img and its not broken ? if this img acculy exsist ?
  3. $page->images->add('URL_from_text'); That looks easy ill check it out later today, thank you
  4. Hi on my site users can post new articles, and withing them upload images i made this: $pic= new WireUpload('fileUploadInput'); $pic->setMaxFiles(1); $pic->setOverwrite(false); $pic->setDestinationPath($upload_path); $pic->setValidExtensions(array('jpg', 'jpeg', 'png', 'gif')); $files = $pic->execute(); if(!count($files)) { $pic->error("Sorry, but you need to add a photo!"); return false; } The above works with <input type="file"/> Is there a way to upload files thru url ? exaple : <input type="text" value="http://processwire.com/site/assets/files/1/fields.jpg">
  5. Yes i noticed that, its all good i want ot use that but only when inside category. On home page i want to be able to click next nad prev and stay within "home page array", I think thats what i was looking for i will test it once im back from work. Thank alot, as allways i can count on your help here. thx very much !!
  6. Hi, im making a website with alot of articles, my structure looks like this NEWS CATEGORY article item CATEGORY article item CATEGORY article item CATEGORY article item CATEGORY On home page im listing all articles from all categories - 25 articles per page. Im opening them in Fancybox Insite article i have next and previous buttons, on click im loading content of article via ajax, replacing content in fancybox. and i change history via history api for seo reasons. My question is: Is there a way to make next and prev buttons change thru articles but listed on my home page (included next pages) instead of picking next or prev from category the article is nested in ? Would be grateful for some tips on that. Cheers
  7. WOW so easy and clear, awesome module just perfect for this thank's guys ! I just had to add link to videos again but its working perfectly thank you mate
  8. Im sitting to my work now il let u know if i get some issues. Thank you for now this helped
  9. Hi, im using this module and it works great, but i need a little twitch. Is there a way to get raw value from textarea? i need to get that link. i got news list and i need to show img (thumb) generated by youtube to display on my news list instead of embeded video. Only in news detail page i want to show video. And i need to get url to modyfi it to get thumb, any tips ? Thanks.
  10. Awesome, thank you guys. Yes, users will be able to create their own topics ( pages ). I think i will go with PW comments, but will try disqus aswell. will see what will fit my needs better. Ty again
  11. About PW comments, i would love to use it, but i need to have nested comments, is this is possible to do? About Disqus, i will have register/login with facebook button on my site. I dont want users to register multiple times.
  12. Thx for replay, Im considering disqus aswell, but i dont want users have to register with the site and then with disqus to post comments. Is PW comments system allow users to reply to their comments ? like facebook comments system can ? About facebook comments ... i cant use it since i want anonymous comments to be avaible. That looks nice, thx
  13. Hi, im starting kind of a social website, and im looking for a good way to enable comments on my site. i need comments to be editable, deletable for admin, and also for user within 10 minutes after posting it. Users can replay to other comments, and comments are also avaible to guests (posting anonymous). I was searching for a good tool to do this and i found this http://posativ.org/isso/. Thing is that im begginer with php, and i get confused after reading 1st line of instalation guide. Did any one did this before and can help me aout a bit ? or is there any other good solution for comments that u recommend. Cheers.
  14. One thing is not working for me dunno why, in API docs i see this should work: $out = __("It's time for you \nto get to the party."); // good but it seams not, here is my code: <h2><?php echo __('Safe \nplastic surgery') ?></h2> Any tips ?
  15. what i mean is to have same solution as : but for front-end. So u can use variables in your page templates
  16. Hi guys, is there a way to translate hardcoded html text for example: <div class="tabs"> <a href="#">Tab name in some language</a> <a href="#">Tab name in some language2</a> <a href="#">Tab name in some language3</a> </div> i know that we can do something like <?php if ($lang == 'en') { echo "<a href="#">Tab name in English languge</a>" } if ($lang == "other ") { echo "<a href="#">Tab name in other languge</a>" } I was thinking about module of some kind working like "Process Language Translator" or in code u use variable tags like : {lang-TabNameInSomeLanguage} <div class="tabs"> <a href="#">{lang-TabNameOne}</a> <a href="#">{lang-TabNameTwo}</a> <a href="#">{lang-TabNameThree}</a> </div> in Admin some sort of table like this with translation for each language we create. Varialbe ENG DEU POL TabNameThree this is tab one dies ist einer Tab To jest jedna zakladka Or there is totaly other easy way that im not aware of ? Cheers Paul.
  17. Hi guys, im searching for an easy to use solution of a newsletter for a PW. Preferably create pages as email addresses thru API for users. I dunno what would be easyer for me, (im not php magician) use some api ? or is there any other easy solutuion? If api then which one. and how to integrade it with PW so it will use my user base. Ty Paweł
  18. If u can install forget password module on your destination server then its easy. if u cant u have to install module on your local, then export it to your destination server when u do that, just try to login in on your destination server and use module to reset password. That allways works for me, and this is how im doing it. Meaby someone have better solution.
  19. Got same problem, thing is i downloaded newes dev version of pw, and now forget password plugin dont work. Usualy i just reseted password and it worked. If u have stable version of PW then all u need to do is reset your password when logging in. EDITED, Ok it works its my bad, previously you had to enter email address now system asking you for username. So ye best way to do this is to reset your password with this plugin, if u dont have it installed then i propose to install it on your local then copy database again to your destination server along with the module files. then when loging in u will have forget password button, enter email address or username (depends on your PW version). and wait for email. Change your password and thats it. I had same problem once now i allways isntall forget password module (its in core)
  20. I just update PW to dev version and it stopped working ;( and im still with the problem. I used this method to not show children of thoes parents: 'selector' => '!parent=1034|1015', but there is page id 1090 within 1015 which i need exceptionally show. is there some method to overrule selector ?
  21. i dont want to show a children of this template, and honestly it works. here is a full code i use for my nav. u can also view the page here: midven.avenueagency.eu Page is still in building process <?php $rootPage = $pages->get("/"); $treeMenu = $modules->get("MarkupSimpleNavigation"); // load the module $options = array( 'parent_class' => 'parent', 'current_class' => 'current', 'has_children_class' => 'has_children', 'levels' => true, 'levels_prefix' => 'level-', 'max_levels' => 2, 'firstlast' => false, 'collapsed' => false, 'show_root' => true, 'selector' => '!children.dont_show=1', 'outer_tpl' => '||', 'inner_tpl' => '<ul>||</ul>', 'list_tpl' => '<li%s>||</li>', 'list_field_class' => '', 'item_tpl' => '<a href="{url}"><span>{title}</span></a>', 'item_current_tpl' => '<a href="{url}"><span>{title}</span></a>', 'item_root_tpl' => '<a href="{url}"><span>{title}</span></a>', 'xtemplates' => '', 'xitem_tpl' => '<span>{title}</span>', 'xitem_current_tpl' => '<span>{title}</span>' ); function hookGetListClass(HookEvent $event){ $child = $event->arguments('page'); // current rendered child page $class = $event->arguments('class'); // the class string already present // any API check on that child $event->return .= " id_".$child->id; // add your custom class to the existing } $treeMenu->addHookAfter('getListClass', null, 'hookGetListClass'); ?> <nav id="main-nav"> <div class="header"><a href="#side-nav" class="dropDown">Menu</a></div> <div class="wrap" data-target="#side-nav"> <ul> <?php echo $treeMenu->render($options, $page, $rootPage); ?> </ul> </div> </nav>
  22. Ok something rly strange happend and after couple of guess'es i typed in 'selector' => '!children.dont_show=1', and hey ! it works
  23. any reason my foreach($pages->find("dont_show=1") as $p) { $p->nav_selector = "parent!=$p->id"; } shows only one result parent!=1034 where there should be id 1015 also?? ye this is not working ;/ i can just choose template as a selector but this checkbox is so nice
×
×
  • Create New...