Jump to content

Ninjakreborn

Members
  • Posts

    3,922
  • Joined

  • Last visited

Everything posted by Ninjakreborn

  1. Screw it, I chmodded it and it worked fine. However for future knowledge it might be cool to find out why mkdir didn't work as expected.
  2. if (!mkdir($docroot . "/geosystems/projectfiles/" . $name, 0777)) { echo "Not-Created"; }else{ echo "created"; } quick example of the type of thing I am trying to use. The directory it's creating is 4 (roughly) levels doop. root/dev/g/projectfiles/created directory here I am trying to set the permissions to 777. But it's refusing to, it's setting them to 0555 755 I looked up and located a bug on php.net There was a fix looking like if (!mkdir($docroot . "/geosystems/projectfiles/" . $name, 01777)) { echo "Not-Created"; }else{ echo "created"; } I tried that fix and it still did not work. I needed to create the directory and give it 777 permissions because the files needed to be uploaded via ftp by the client, then I have other scripts automatically getting the file's "from" that directory. Any advice?
  3. What is a simple way to validate a string to make sure it doesn't have any spaces, and doesn't start with a letter.)
  4. Now I think it looks "bad ass". That is what I am talking about, very nice. A few more ideas on it. 1. The contact form, make it within the same layout (same border and the navigation) - just advice. 2. I LOVE what you did with the about us page, very nice. Very nice.
  5. No, not an extension and actual class. One that has extensive information variables, benchmarks, execution times. Just lot's of different things you can see related to debugging. I was 2 but they weren't exactly what I was looking for.
  6. I didn't see a set of rule's. I have 2 questions basically. 1. Is it against the rules of the OOP Help board to ask if anyone knows of a good class for "whatever". Or is that against the purpose of this specific category. 2. If not then does anyone know of a good PHP Debugging class. I found a few, but I was hoping to find something really powerful. I found something big but it had too advanced of an install. it used JavaScript and it required a separate installation, I want an actual class that has a bunch of really good stuff for debugging. Any advice appreciated. Note: If this type of post isn't allowed in this category then delete it and I will pretty much get the hint to post in the miscellaneousness board at that point.
  7. hmm, I think based on what I learnt today. I won't ever look at all database systems the same again, I will actually do research on the strengths/weaknesses of each and report what I find here, and reference urls. Thanks.
  8. I finally got it thanks to help from some other posts where I was more specific, thanks.
  9. Yes, but it's still helpful. I saw people doing this, and they called it "modular programming" but I never fully understood it. When I try to make a function for something that large it ends up taking awhile, but if I did then I could reuse those functions for other projects. I will keep that in mind, thanks.
  10. Is there somewhere I can find like a list of some of the strengths/weaknesses of the different database systems (relational/non-relational). I want to learn which one's are better for which purposes, and how to tell the differences. Thanks for telling me this. I want to find out more about it.
  11. Couldn't get that to work, I finally just modified what I had on the other part and everything work and tested out right. Atleast that's over with one more part to that and everything is fine. <?php $sfees = "SELECT * FROM cy_members"; $squery = mysql_query($sfees); $feeok = 0; // to report number of successfully billed accounts. $feeerror = 0; // to report the number of failed account billings. while ($srow = mysql_fetch_array($squery)) { $curr = date("m/d/Y"); // get current date $lastbilled = $srow['system_lastbillingdate']; // last billed $lastbilleddays = mktime(date("h", $lastbilled), date("i", $lastbilled), date("s", $lastbilled), date("m", $lastbilled), date("d", $lastbilled)+1, date("y", $lastbilled)); $lastbilleddays = date("m/d/Y", $lastbilleddays); if ($lastbilleddays == $curr && $srow['system_currentdueamount'] != 0) { $newamount = $srow['system_currentdueamount'] + "10.00"; $insertnew = "UPDATE cy_members SET system_currentdueamount = '$newamount' WHERE mem_id = " . $srow['mem_id']; echo $insertnew; if (mysql_query($insertnew)) { $feeok++; $feesuccess = $feeok . " accounts had late fees applied successfully."; }else { $feeerror++; $feefailure = "There was a problem with calculating late fees for " . $feeerror . " members this month."; } } // unset variables on passthrough to prevent potential issues. unset($insertnew); unset($newamount); unset($curr); unset($lastbilled); unset($lastbilleddays); } ?>
  12. Anybody, this is driving me crazy. Anyone have a functional function (take's date 1, date 2) and returns the amount of day's they are apart. Need to figure out something here. Thanks.
  13. Logic, think about it. $result = mysql_query("SELECT *,((system_nextbillingdate-".time().")/86400) AS days_late FROM cy_members"); That is the query. Ok result = (result holds the informaiton (obviously) mysql_query (runs a query) All basic stuff BUT now we have SELECT (get) the unix time stamp of the next billing cycle MINUS the timestamp of the current date DIVIDED BY 1 day's worth of seconds. Then save that info in the variable days_late from the table cy_members. That's it, I just don't understand the logic behind. I mean I do, but I have to account for the fact that I need to change out the days. He asked me to start it at ONE day then late change it to 15. I understand what it's doing, but going through the calculations I don't understand how it works.
  14. ((system_nextbillingdate-".time().")/86400) That is the part I don't understand. The next billing date is there upcoming payment. But I need to calculate 15 days after there billing cycle (the last date they were billed, which is actually system_lastbillingdate). What I get from this is get the nextbilling date timestamp - the current time dividied by 1 day's worth of seconds???
  15. Ok, I was about to implement this, and I understand how it'll work but I also ahve to have the "day" able to change out. Like the day variable be able to change how many day's it can be late. Like 1 day they get late fee's all the way up to like 15 days they get late fee's (I need the grace period to be changeable.)
  16. Also can the above properly account for the fact that it may not be late at all. If it goes to a user who is not late, will it ignore them completely. If one is 5 days late it needs to ignore then, 10 day's late ignores them. If they are actually 15 day's late then I can do the appropriate actions, is the above correct for that, thanks.
  17. Cron Tab, thanks. I will also check into other services that do that, it would be nice if they had a free service somewhere and you could create an account and login. Then register crons. They could have like a security feature where you have to insert a meta tag into the site so they know you own it or have access to it. Then you would sign up for an account and register whatever sites to get crons sent to whatever page. That would be cool.
  18. Ok, let me make this a simple question. Is the following correct. <?php $sfees = "SELECT * FROM cy_members"; $qfees = mysql_query($qfees); $feeok = 0; // to report number of successfully billed accounts. $feeerror = 0; // to report the number of failed account billings. while ($rowfees = mysql_fetch_array($qfees)) { $days = 15; $cdate = date("m/d/Y"); $cdate strtotime($date); $duedate = $rowfees['system_nextbillingdate']; // due date as timestamp $latedays = $date - $duedate; if ($latedays == $days) { } } ?> Ok basically I need to get the number of day's they are late, so I can do some math with it. Will the above properly retrieve the number of late days.
  19. Is there a way to run a cron job without the ability to run a cron job. For instance if you are making an application, and you have a lot of system stuff that need's to be ran. Can you setup something with just htaccess to run a cron, or have something else that you do that will run a cron. Or is there a third party company (business) where you can sign up for a free account and register cron's there, and it would actually run the php scripts within those intervals, and since it's an external source doing it, you are guaranteed it'll work because it can be done with any server. Something.
  20. Ok, I am about to start, I know how to do some of it, but seriously. Getting some advice on the calculations would help a lot...
  21. In your banner if you look into the graphics you see a rectangle type object inside there (it's got a border around it), I think replicating that border around the site as well (around the sides of the site (maybe top/bottom but not sure), then it would look a lot better.
  22. Oh, I had no idea what you were talking about at first, thanks.
  23. Not that I know of, it's something you will have to get creative with a little. I have never had to do that, I just provided those because they will remove any difficulties with actually working "with" pdfs.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.