
Iluvatar+
Members-
Posts
100 -
Joined
-
Last visited
Everything posted by Iluvatar+
-
Object Oriented Programming Or Traditional Coding?
Iluvatar+ replied to mostafatalebi's topic in PHP Coding Help
A bit dramatic dont you think? -
My post?
-
Object Oriented Programming Or Traditional Coding?
Iluvatar+ replied to mostafatalebi's topic in PHP Coding Help
If you ask for an opinion you’re going to get an opinion and most likely a justification. You have stated you’re a programmer who is competent in both methods of development therefore you should know the pros and cons of both. If you are unaware of the pros and cons take these options and justifications as good advice from people who do understand the vast difference between the two methods. -
$24HoursAgo = $currentTime-3600*24
-
The 24 hours before will be a dynamic value so it would have to find out on exercution..... [color=#000000][color=#0000BB]<?php [/color][/color] $24HoursAgo = $currentTime-3600*24 [color=#000000][color=#007700]?>[/color][/color] myslq.. SELECT * FROM content WHERE `live` LIKE '0' AND time !> '$24hoursago' ORDER BY date DESC LIMIT 40
-
I have never used wordpress but i am guessing get_posts is a query method, try print-out '$args' array using echo '<pre>'; print_r($args); echo '</pre>'; See how the data your querying is structured and you should be able to work it out from there
-
Object Oriented Programming Or Traditional Coding?
Iluvatar+ replied to mostafatalebi's topic in PHP Coding Help
It is in fact a matter of option however the advantages of OOP in my own options are far greater than the out dated un-structured messy procedural approach. My advice to you is take the project into account if it requires an extensive amount of code them OOP way is prob the best root for you for the following reasons... - Organization - Reusability - Flex ability in frontend development (ability to change allot without messing with the data controllers) - More secure to use public, private and protected methods (php 5 +) ... the list can go on. If you require a simple sever side solution on an simple website then i see no floor in using a the procedural method -
How To Put Aq Simpel Jquery Pop-Up In A Php File?
Iluvatar+ replied to crf1121359's topic in PHP Coding Help
huh? What is it your trying to do?, run the php code with jquery or place the jquery in the php file. You have to be a little more specific. -
<?php if(isset($_POST['var1'])) { $newVar1 = $_POST['var1'] } ?>
-
Validation Text Area To Dont Let Insert Emails Or Website Links
Iluvatar+ replied to madness69's topic in Javascript Help
By all means use front-end validation for extra security but trq is right you should have your validation set in you server code. For the front end validation i would make your life a lot easier and use JQuery. Really simple example that i just tested $(document).ready(function(){ var blocked = ["http://","@",".com"]; $('#myTextBox').blur(function(){ for(i=0; i < blocked.length; i++) { var blockedVal = blocked[i] if (this.value.indexOf(blocked[i]) >= 0) { alert(blocked[i]); $(this).css('border','1px solid red'); } } }) }) -
I thought that but i have pasted in in to notepad before i put it in the d/b but i am still getting. There is nothing odd about my code i have just done a simple foreach loop from a mysql_fetch_array. <?php while($row = mysql_fetch_array($Macros)): ?> <tr> <td width="150px"><?php echo $row['title']; ?></td> <td style="text-align:right;" class="BtnRow ApplyMacro" title="<?php echo addslashes($row['content']); ?>"><a class="Btn">Apply</a></td> </tr> <?php endwhile; ?>
-
Geting question marks insead of comma's when i pull chucks of text from my database. Prob a simple way around this but for some reason i cant find anything that can help me so far. Does any one else have a solution for this?
-
Get the email body without the email footer
Iluvatar+ replied to son.of.the.morning's topic in PHP Coding Help
I am guessing he is asking if there is a way you can get the email main body of an email without extracting/storing in appending data (reply?s and what not). It seems we have the same issue as i am trying to do something similar. -
I have two tables 'bookings' & 'refnums' in the bookings table i have a foreign key of the 'id' coloum in the 'refnums' tables. I need to query the refnums table so i get all the data from both tables in related order but i need to only bring back the results via a spefic date in the Booking table. I have related both tables in the refnums model but i dont no how to use WHERE condisions to only bring back the results from the bookings.date_booked. Anyone have any ideas.
-
Cool man, i am sure ille come up with a solution at some point hahaha
-
To go forward and backwards within Ajax calls
-
I am at the early stages of developing a booking system (in cakephp) that can be used by both the client and the admins. The process in which a booking will be made is Select a treatment -> Select a therapist (that is linked to the treatment) -> Select a day -> Select a time - > Keep in mind that the day and times will be based on the therapist time sheet which will be inputted by an admin. I have already got a clear idea on the majority of the logic of the application although I am having a trouble thinking of a solid logic in how I can display time availability of the therapist. Has anyone one done anything like this before or anything that could help me.
-
Anyone no of any good ways of implements Ajax crawling ability in cakePHP. (Keep in mind i am using the Js helper inbuilt in cakel.)
-
Hey, I have a foreach loop displaying some data from my table, what i need to do is run a Jquery each function on the repeated element so it fadesIn each element one at a time. I am guessing i need to set somesort of interval for this to work. I have been messing with it for a good hour or so now and i cant seem to get it working. Has anyone done this before or seen it done else were?
-
I need to write a code were users can login to his/her email account from my site to import contacts to be selected and used. I know you need to use api's for this. Has anyone done this before who can give me some useful tips?
-
Has anyone ever used these. I want to develop a tool so users of my site can invite there friends.
-
Any one know a way of over-riding the default CSS styles on HTML5 based facebook widgets. Driving me mad trying to find a solution.
-
Is there a diffrent image type refference in php for the file extentions 'jpg' & 'jpeg'. For example i have allowed "image/jpeg" files to be uploaded but only files with the extention .jpg are going through were as .jpeg are not, any idea's?
-
Alright guys, just wondering if any of you have actualy used this? I am having trouble trying to use limits in my queries. <?php ... $newThisMonth = $ga->requestReportData(ga_profile_id,array('visitCount','Month'),array('newVisits'),'-newVisits', $max_results='1'; ... ?>
-
I was referring to site statistics hence why i was thinking about using Google analytics.