-
Content Count
3,324 -
Joined
-
Last visited
Everything posted by truefusion
-
I thought i had joined this topic a long time ago, but i guess i haven't. Seems fun. I got .exe for file format. Windows XP for operating system. Python for programming language, which i have to say Python has been known for good performance for a while.
-
Flat Files! Good Or Bad? Whats Your Opinion!
truefusion replied to KansukeKojima's topic in Websites and Web Designing
I've seen flat-file guestbooks before, but i'm not entirely sure how they get around certain security implications. There are also popular flat-file CMSs out there. If you examine their ways, you could eventually come up with a theory on how to build a flat-file forum. I'm not sure if Craig's List uses a flat-file forum, but if so, then i'm impressed. I haven't attempted to do any flat-file based scripts outside of CMS, shoutbox and image gallery, but a forum with multiple users that is flat-file based and secure would be interesting to see. I know you can place files outside of your public_html folder to access things from there, making certain things secure, but i haven't tested working with a script that creates everything outside of your public_html folder. I would assume that would be your best bet, though. -
Well, RAM will always be quicker to access than a hard drive. The 10k+ RPM hard drives can be useful for faster SWAP. If one is using a computer with a low amount of RAM where they are constantly low on RAM, these faster hard drives would be quite helpful. But, again, unless you're placing really big files into memory (e.g. 2gig. file), or just constantly moving them around, or constantly making back-ups of entire systems, then it will most likely not matter if your hard drive is 7,200 RPM. Let's say the 7,200 RPM hard drive transfers at 1.0gbits a second, and we're trying to transfer a one gigabyte file. That would take about 8 seconds to fully transfer the file to a location that can receive at the same speed. But once the file is in memory, access to it will be a whole lot quicker if the operating system has good memory management, like Linux.
-
Question About Multimedia Player VLC - Windows Media Player - Etc.
truefusion replied to rpgsearcherz's topic in Software
Rather than having the video on top of all other windows and transparent, lower the media player to the bottom (i.e. "Keep Below Others", under the Advanced menu—in KDE4) and just have the windows on top transparent. That way you'll not only be able to watch the video but also use the program(s) above it. Since, if i remember correctly, you have Vista, i suppose it is safe to assume you have a graphics card that supports 2D acceleration and compositing, so you shouldn't experience any lag if the drivers for the card are good. However, this isn't really limited to KDE4, but KDE4 doesn't require the installation of Compiz-Fusion. -
Question On Mycents seem to be stuck
truefusion replied to Echo_of_thunder's topic in Web Hosting Support
Rather than a question on myCENTs, i have a question for others which i have been wondering about: For those who say that they have lost, what method are you using to conclude that? Is it via the forums, whether by your profile or the user information on the side of each post? Or by logging into the Xisto - Support Billing Client Area?I ask this for a couple reasons: [1] the total earnings shown in the forums, at least for me, have never reflected the amount found in the Billing Area, and [2] even though i have seen my and others' total earnings as shown in the forums decrease (though slightly), it has eventually (similar to what mahesh2k said) reverted back to the expected amount. Though there are slightly more reasons for me, these are the main reasons why i haven't been worrying about any "losses." -
The same argument can be said for anti-malware programs, so how can you trust them? In fact, a program doesn't even have to be malicious in order to act like a malicious program. That's known as "unstable" software—"use at your own risk" software. No human is omniscient where they are able to prevent an attack before it occurs. You can't fully depend on any software for protection. The main advantage that other browsers have over Internet Explorer is that Internet Explorer is integrated into the system. In fact, you can switch from Internet Explorer to Windows Explorer, and vice versa, simply by changing paths (or URLs)—that is, from a URL to a path on your file system. I remember a problem that a family member had where they could not access, nor open anything in, the Windows Control Panel. How did i fix it? I opened up Internet Explorer and hit an option that allowed me to reset Internet Explorer's settings. Wow! i have to say. The solution was so simple (though totally out of the range of common sense—i mean, how does it follow that the settings of Internet Explorer can affect the Control Panel and its programs?). Talk about integration. Now, Konqueror is known to be a browser with file-managment capabilities. However, though you can switch from browser mode to file manager mode, it is not in any way integrated with the system as Internet Explorer is. If Konqueror gets corrupt, it won't mess up KDE nor the system. In fact, you don't even have to have it installed on the system. I've heard about many people try to get rid of Internet Explorer on their systems, only to have their Windows system become unstable afterwards. So, no matter the education or arguments for Internet Explorer, it will always be the case that using another browser is the safer bet, though a bet it may still be. At least with these browsers you have a more active development than Internet Explorer, meaning bugs are generally fixed faster than Internet Explorer.
-
Flat Files! Good Or Bad? Whats Your Opinion!
truefusion replied to KansukeKojima's topic in Websites and Web Designing
My website runs off of a flat-file CMS i made specifically for my site. Some discussion in this topic talks about that an actual database requires less work when coding a script to work with a database, is more secure, and is not prone to multiple-edition errors. I will say that that is not always the case, if at all. In my case, my flat-file CMS has not only allowed me to perform less management for my site than what i would have to normally have done if i had gone with a website that requires a database, but compared to the database CMS i have been working on (found in my signature), has a significantly smaller filesize than my database-based CMS. To emphasize a key advantage for my personal, flat-file CMS over a database-based CMS is that in order for my site to list the file i created, all i have to do is upload it into a folder that my script is told to scan in (which does not require to have any of my files to have write permissions). Database-based CMSs do similar but in their own way, but, as for my case, would not allow mass page-creation outside of a database restoration. From my experience it requires more work for a database-based CMS than a flat-file CMS, since there are less security concerns to worry about, and less files to perform different database-accessing tasks (whether it be for user login, page creation, page editing, etc). -
As rvalkass said, it allows for faster transferring and access of files that are pretty (or immensely) big. But in practice, unless you work for a media company, where HD videos with pretty big resolutions and similar, or if you download things illegally (since this is the main cause for mass memory income, which i am against, of course), then you won't really need more than 7,200 RPM. Concerning games, the game will almost always load (i.e. if there are any exceptions) the map before allowing you to play, so the speed is somewhat irrelevant, unless you are impatient, not wanting to wait a mere extra 2 (more or less) seconds compared to faster hard drives.
-
For an auto-incremented field, you don't need to supply the number; it's better if you don't. So instead of supplying a number, supply null instead. Also, you don't have to provide every field in the table to insert things, you only need to provide the fields you're going to be inserting to. mysql_query("INSERT INTO `matri` (`sno`, `name`) VALUES (NULL, 'sanju')");I'm not sure how you're viewing the database, whether through this script, MySQL Query Browser, PHPMyAdmin, or other, but if it's through this exact script you have posted, it's not going to show the results. And if you want to retrieve data, select from has to come after the data is inserted.
-
I shall assume a few things for this: [1] You already have your form set up with the input fields named properly, [2] you use the POST method for the form, [3] your script is already set up to connect to the database and is included in the necessary pages, and [4] your table has a column that auto increments (and is the primary key) named "id." Since the POST method is used, we have to use the predefined PHP variable, _POST, to obtain the values from the submitted form. For security reasons, we shall use mysql_real_escape_string to filter out the values in _POST. This is easily achieved with array_map since _POST is a variable that holds an array. $_POST = array_map('mysql_real_escape_string', $_POST); The function mysql_query is pretty much self-explanatory, to execute MySQL queries. You want to insert into the database the values retrieved from the form. mysql_query("INSERT INTO `matri` (`id`, `name`, `dob`) VALUES (NULL, '".$_POST['name']."', '".$_POST['dob']."')");To get all the data in the database you use select from. if ($query = mysql_query("SELECT `name`, `dob` FROM `matri`")){ while ($result = mysql_fetch_object($query)) { echo $result->name; echo $result->dob; }}
-
Is Facebook A Threat To A New Social Community Today?
truefusion replied to africa's topic in Websites and Web Designing
Social websites like MySpace, Facebook, etc, have people who work on it almost everyday, coming up with new ideas, fixing bugs, etc. If you're going to make your own, you'll have to put in similar effort into the project if you truly want around 10,000+ users. Since these other social networks are up, there will be some competition from them, and probably people wondering, "How many users does this site have?" I don't know how these other social websites started out, but they've obviously had time to grow. Social networking sites can't be themselves without users. Indeed, you'll have to have something interesting about your site. Extraverts are key for social networking sites, so is advertising. You could target one area, then after rooting yourself, spreading to others. -
Sending Email Problem In Php please help me.
truefusion replied to contactskn's topic in Programming
Where are you testing this at? On a local server or remote? If on a local server, bear in mind that PHP cannot send mail on its own and requires a MTA that supports SMTP, like postfix or other, to be installed on the server and configured properly. If on a remote server, then you may want to contact the administrator to see if the PHP mail function has not been disabled, etc. -
Been messing around with D-Bus for Pidgin in Python and thought it would be interesting to have an OSD instead of a toaster pop-up script for notification of new messages. In turn, i wrote a script that brings that thought into reality. You can manually adjust the width and height of the OSD. Currently the script shows the display centered near the bottom only. You can also set how long you want it to last and the amount of opacity. Since i am unsure how to make Pidgin handle it as a plug-in, the script loads outside of Pidgin, with its own system tray icon. The modules for Python required for the script are the Qt4 Python module and the D-Bus Python module. Download
-
If you already ordered one in the billing area, then all you need to do is wait for confirmation. It's not an instant set-up that occurs when placing an order. I'm not entirely sure where you received the message you posted in this topic, nor do i know what a "shoting account" is, but if you received the message in the forum, then it has already been addressed. If you received it in the billing area (though i don't know where one can receive that message in there), then it's probably due to what i previously mentioned, that it's not an instant set-up.
-
Existance Of Jesus (aka Christ) Core of Christianity
truefusion replied to kelvinc2's topic in Health & Fitness
[1] You're still begging the question: you have yet to show that He isn't doing anything, even in the least. You might be able to show that He's not doing anything according to "your" standards (though standards can wave), but it doesn't follow that He's not doing anything. [2] It may have a lot of metaphoric parts, and even what is literal can be taken metaphorically (though frowned upon Biblically), but that doesn't mean all those statements you saw in that other topic have no literal bearing on reality and therefore should be considered fully (or any amount) metaphoric. [3] Though it is perfectly logical to stop asking questions when you have all knowledge of the universe (and things beyond it), i don't recall any believer proclaiming, "I know everything." Even one of the early church fathers, St. Augustine, said that interpretations should change when new knowledge is discovered if they contradict each other. Note that he did not say that what is written should change. And if you're going to bring up how "ambiguous the Bible is" from this, do keep in mind that science does the same thing when new knowledge is found that contradicts a previous interpretation. After all, all evidence is interpreted. [4] Genesis only mentions physical imperfections, not metaphysical ones. God created Adam and Eve pure and without sin, just like every other being that followed. All those metaphysical things came after the Tree of Knowledge of good and evil. But why would i blame a rich person for trying? And if you're indirectly accusing God, again, you would be begging the question again. [5] To answer your question on if the story is familiar, i thought you would conclude something else rather than some rock being at the right place at the right time. Personally it sounded it was along the lines of the paradoxical question, "Who (or what) created God?" Why did i think that? Because we were backtracing how things are affected by each other. To put it in a visual way: we <- environment <- universe <- ???. Concerning your other question about the rock at the right place and right time: Yes, it is hard to believe in that, because how would a mere rock not only be able to split itself to cause other rocks into existence, melt itself, but also form an atmosphere around itself for life to even have a chance at survival?—that is, at least without divine intervention. [6] Sure ignorant people are easier to influence, but you do realize you are begging the question again (though it started way back though i didn't say much about it) by claiming the church hated (scientific) knowledge, right? Just so that the burden of proof may weigh more on you so that you may see clearly my accusation, i'll give you a site that quotes St. Augustine, an early church father, on the exact thing you're talking about: http://www.pibburns.com/augustin.htm [7] I too do not know why God caused existence into being, but i shall ask you (an objective) question: What book or site implanted the idea in you that God is impersonal? If no book or site, then how can you, a person who seems to be just like those in the "Unholy Trinity," trying to abolish faith (or religion itself) for the "sake of knowledge," convince yourself (through logical means) that God does not intervene even in the least? [8] That basically says don't rely fully on what is seen but consider what is unseen. I already read that allegory, though; still find it interesting. And if you quoted that for proving or supporting ideas that you've been mentioning, then it is a bit counter-intuitive. [9]Ah, but that follows for unbelievers as well. (I can't remember if i've seen that one before, though.) -
Switch to a Sans Serif font for the base font so things won't seem so crowded. The text in the footer on a computer with low gamma would be impossible to read, if one can even notice it in the first place. The categories color could use a darker green (i.e. "Sample Posts," "inverse undoing," etc). The featured posts section, the images could be rotated in perspective, shrunken a bit with a nice reflection under them. Since this is basically a mock-up, i will assume that any text alignment will be fixed when completed (released). On the right side where the boxes with the text on top of them, above each box you can have kind of like a blurred square-shadow, as if the light is shining somewhere below the middle from a distance. Then you can make the text there a bit glossy and center the text. For the banners at the end of each post, you can have it have its own edged box (if you will) like you do with the post titles, where you indent or cut off the box and make it appear like it is behind it. Also, some style or some kind of emphasis may be useful for the author's name. That's pretty much all i have to offer for now.
-
Existance Of Jesus (aka Christ) Core of Christianity
truefusion replied to kelvinc2's topic in Health & Fitness
[1][8] You still have to prove that He enjoys it. So to you there "appears" to be "nothing" being done instantly about "any" annoyances and inconveniences. That doesn't prove that He enjoys it. So we simply love it when things that are in our favor happen quickly and instantly. Your entire statement begs the question in that it assumes God is a sadist and runs with it. I've already said that Christians gain their inspiration from God—and them apparently being the ones moving around the most. I do not know why things don't happen instantly, but at least things are done about them. There have been times where i've acted like a "microwave" person and regretted it later, seeing how foolish it was to want things to happen instantly or quick. You can't blame God for doing nothing if He isn't doing nothing. It is, also, unjust to blame God for the actions of the people; there are still millions of people out there who do nothing, not even donate though bearing more than enough money, to prevent such things. In a world seeking separation from God (i.e. a godless world), who wants to be moved? Or, rather, who is there to move? If existence was limited to how evil a being appears to another being, then millions of people (if not all) don't exist. The Biblical account, though mentioning that our design is not perfect, alludes that the Garden of Eve was a safe haven, where imperfections were not active. [2]Strange, i thought you posted in this topic. How'd you miss all of those facts? But to imply that the Bible excludes life outside the earth is obviously false. Like i mentioned before, that is to deny the existence of not only angels, demons, but God Himself. Second of all, there is no explicit statement in the Bible that excludes other physical beings outside the earth; even Genesis 1 gives enough room for other, physical beings outside the earth. "The church" does not have to admit to anything, nor does the Bible magically get its text rewritten for "new" knowledge. To add to this, i'll take you through a part in Genesis 1 to show just how open Genesis 1 is to even dinosaurs. Gen. 1:1, the age-old saying, introducing what God created after bringing time into existence. Gen. 1:2 states a water world but does not state that God created the earth right then and there, but alludes that the earth existed for some time before God decided to start forming creation as we know it today. Because of this opening, we can obtain a glimpse as to how the dinosaurs became extinct besides the theory of evolution; that is, an actual world-wide flooding (unlike Noah's time, as the flood in Noah's time wasn't world-wide in that same sense). That means the dinosaurs were drowned. Those in the air had no place to land except the vast ocean; those in the water were alive till their food supply ran out. Then in Gen. 1:9-10, God causes land to rise from under the water. Earthquakes caused by this could be the reason why dinosaurs were under ground. I'm not sure if cold water, where the pressure at that low level is really tight, can help in the fossilizing of bones, but there's another task for scientists to enjoy themselves with. That ends my tour; so you can't say the Bible has nothing to offer whatsoever for the scientific community. [3] We can accept an infinitely big universe (that's why the context on my other post talks about the expansion and contractions of the "universe," since it is about the size of the universe), but since nothing cannot logically output something, it becomes quite difficult to accept the opposite, that nothing can output something, without a god. It could be infinite in space and time, but the Big Bang theory is showing otherwise. Also, even if it was shown to be infinite in space and time, it does not follow that there is no god; but it would be reasonable to say that that god does not create (i.e. is not a "mover" at all) if it was shown that the universe is infinite in time and space. [4] Though i may not be a theologist, if what makes them appear like they know everything can be applied to me, then i am proud that i know everything. [5] (I had to check the image in Firefox as for some reason it wouldn't show up in Opera.) Not necessarily, i only responsded according to what you had presented. The Bible gives at least 5 reasons as to why situations like that exist (i am not sure of any others, though). These reasons were taken from Genesis, Exodus, the book of Job, etc, but i don't remember them all. But your beginning statement presumes that not believing is the cause of condemnation; it's in a way begging the question. This presupposition is common among atheists, and is due to atheists trying to interpret certain statements from the Gospel of John without taking into consideration basic Biblical principles; that is, when atheists try to be theologists. The two main statements can be found in the Gospel of John, chapters 3 and 5. But rather than taking you through another tour of the OT for its basic principles, i'll merely show you verse John 8:24 which summarizes everything down to a sentence. As for the part below the picture: Actually, the Bible says God sends rain on everyone (Matthew 5:45) (rain back then was very important, as it helped their farms produce, since there was no plumbing like today) and that the unbelievers' prosperity is not necessarily theirs (Job 21:16). Sure, the Vatican can donate more, but i don't think handing over God's power over to a human would be such a good idea, even if there is some good intentions in the human. But i'm not sure what you mean about me advertising. But since we don't need God to provide for these people, i guess complaining about God doing anything is pointless then, huh? [6] By talking about mother nature in his book, he implies a conscious that doesn't exist (where he obviously believes doesn't exist even though he mentions it). Darwin's speech, though in the beginning of chapter 4 defines natural selection, makes mother nature appear like "she's" the one doing the selecting, even though "selection" doesn't bear it's practical definition; that is, where one chooses something. But, yes, it is that "long run" where, through natural selection, all things that aren't beneficial are tossed out. So the only way to even explain how there can still be life-threatening mutations is to say that the environment changes just as much as the organism itself. Meaning the environment is always one step ahead of the creation. But if the environment changes, what causes it to change? If the reason why organisms change is due to complications in the environment, then what complication is there that would cause the environment to change? i don't think i'd live long enough to view even one person take one step for that mile. In fact, i don't even think since humans (i.e. homosapien-sapiens) have existed anyone has even taken that first step yet. But i noticed a lot of that "proof" has been mostly appeal to probability and begging the question. [7] Yes, my statement can be summarized to: Since the reason why you say we lived in the dark ages was due to our knowing, our not asking, "Why?" you say things concerning the Bible made us know everything, and that by asking, "Why?" again, we'll get out of the dark ages. That is, with knowledge we obtain light and therefore come out of the dark ages. Yet you admit we had knowledge during such dark age but want it to go away by asking, "Why?" again. Basically you want us to start all over again from the beginning so that we can leave the dark age which we should have already had left due to having knowledge in the first place. Following this logic means that knowledge brings us into a dark age. That's counter-intuitive, since you want people to obtain knowledge all over again. Meaning, regardless of what science has to offer, science would place us into a dark age. [9] Ah, yes, logic does seem to neither be able to prove nor disprove, eh? For in the end, even if it is not the case of the Biblical God, it does not follow that there therefore cannot be any god. But you're basically saying that the God hypothesis is a tautology. But i do not see how such hypothesis becomes less reasonable due to it being a tautology, for that would make math itself less plausible. But i can't think of anything that would make me drop my belief in a god either. However, i am unsure what i can prove you wrong in. And i am unsure why God not being bound to (assuming) physical laws has to do with it. And though i wouldn't necessarily say it is a law He is bound to concerning (assuming) moral laws, nevertheless He probably used His characteristics for bringing about many moral laws to the Jews. [10] Seen that quote before; i've seen plenty, mostly from the religous tolerance website (which i find to be oxymoronic in its ways). But the ones from George Carlin i have not seen. -
You need to provide overflow: hidden and specify a width that is shorter than the length of the text as well. I tested it in Opera 9.62 and it works there. Tried it in Firefox 3.0.4 but doesn't work there; maybe in Firefox 3.1 it might work. Tried it in Konqueror 4.1.3 and it works there. <div style="width: 100px; text-overflow: ellipsis; -o-text-overflow: ellipsis; -icab-text-overflow: ellipsis; -khtml-text-overflow: ellipsis; -moz-text-overflow: ellipsis; -webkit-text-overflow: ellipsis; overflow: hidden;">
-
I haven't checked your site, but you seem to be trying to do similar to text-overflow. If so, just use the CSS and have the browser do all the work. That way, upon hover, you can have the text "complete" itself.
-
Ie 5 To 8 Look Out IE Users of 5 to 8 beware
truefusion replied to Echo_of_thunder's topic in The Internet
It's hard to tell from the articles themselves of where or what the exact problem is, but intuition tells me it has to do with ActiveX. This makes more sense when the article talks about gaming websites, as ActiveX can and has been used for gaming purposes. And ActiveX has been known to be a potential security flaw, which all Internet Explorer browsers support, therefore making it Internet Explorer version-independent. But if my assumption is correct, then it is easily avoidable and one need not worry about it. Can anyone make sense of this statement? What's 0.02% of the internet? Also, if we assume that IE7 is the most used version of IE out there, then it is easy to conclude that IE7 is the one that is most effected. -
Advanced Electron Forum Has anyone tried it?
truefusion replied to Running With Scissors's topic in Software
I think most of us have heard of it through jlhaslip's promotion of it. I wouldn't call it new, though. I have it installed on my website. Jlhaslip might even let you test out the admin control panel if you ask him, before installing it yourself. I personally like the Vista-like look to the forum, and i kind of prefer this forum over SMF for some unknown reason. -
A couple of years ago when i was doing some research on health, medicine and doctors, i ran into articles that talked about similar situations with doctors. Although the ones i read about didn't go about giving cars or other major things like that, drug companies do sponsor doctors for promoting their drugs over others. It's not necessarily that the doctor feels that the one they're giving you is better than the others, as the others can be just as good or better—and probably more affordable. It's a source of income for the doctor as well, where the doctor apparently feels justified by the information given out by the drug company to the doctor about the drug—if the drug works to some extent, what would the doctor have to worry about? If they get some extra income while getting the job done to their personal standard, they will continue promoting the drug. Bribes corrupt, high standards will be lowered, and more bad practices will occur.
-
Rather than manually typing out all the pages on my site with their location, priority, change frequency, etc, i decided to type out a PHP class that would do that for me. My site runs off of a flat-file CMS i made specifically for my site. The URL pattern may possibly change in the future (though i'm liking the current set-up), therefore rather than having to update the XML data manually for any new format, why not have a script do that for me, especially if i'm going to be adding lots more pages? The class supports both dynamic and static pages. It was built for general purposes, therefore if you want it to support your CMS, you'll have to subclass it like i did with mineâthat is, if you want to keep this class as general as possible. I was looking at free, online sitemap generators provided on the Google Webmaster Help Center, but they didn't seem like they could be used for general purpose. My script also allows importing directories: it scans a designated directory and picks out all files therein for indexing (currently doesn't support recursive scanning, though). Also, if you don't want the script to be ran everytime the Google bot (or whoever) peeks at your sitemap, you can have the script export to file all the pages you told it to, and you can have a cron job run the script at certain periods to update the sitemap. For static files it automatically checks to see when it was last modified and renders that time in accordance to the W3C date-time standards, which is what Google accepts, to the lastmod element. The script automatically applies your site's URL to the beginning of all page URLs, so there's no need to, for example, apply http://forums.xisto.com/no_longer_exists/ to the beginning of news.html. The script validates well with W3C and Google. The Class <?php## [url="truefusion.trap17.com/"]truefusion.trap17.com/;## Google Sitemap XML generator#class sitemap { function sitemap($priority=NULL, $changefreq=NULL) { /* * (double) $priority: * Range: 0.0 - 1.0 * * (string) $changefreq: * Possible values: * always * hourly * daily * weekly * monthly * yearly * never */ header("Content-type: application/xml"); $this->defPriority = $priority; $this->defChangeFreq = $changefreq; if (!preg_match('`/$`', $_SERVER['DOCUMENT_ROOT'])){ define("DOCROOT", $_SERVER['DOCUMENT_ROOT']."/"); } else { define("DOCROOT", $_SERVER['DOCUMENT_ROOT']); } define("SITEURL", "http://".$_SERVER['SERVER_NAME']."/"); } function addDynamicPage($pagename=NULL, $categories=NULL, $keys=NULL, $lastmod=NULL, $priority=NULL, $changefreq=NULL) { /* * assuming URL: [url="http://localhost/cat1/cat2/file_name?key1=value&key2=value"]http://localhost/cat1/cat2/file_name?key1=...&key2=value[/url] * * addDynamicPage * ( * "file_name", * array("cat1", "cat2"), * array * ( * "key1" => "value", * "key2" => "value" * ) * ) */ if (is_null($priority)){ $priority = $this->defPriority; } if (is_null($changefreq)){ $changefreq = $this->defChangeFreq; } if (is_array($categories)){ $categories = implode("/", $categories); } $this->dynamicPages[] = array ( "loc" => (!is_null($categories)) ? htmlentities($categories."/".$pagename.$this->implodeKeysWithValues("=", $keys)) : htmlentities($pagename.$this->implodeKeysWithValues("=", $keys)), "lastmod" => $lastmod, "priority" => $priority, "changefreq" => $changefreq ); } function addStaticPage($loc, $priority=NULL, $changefreq=NULL) { /* Forces "current working directy" to DOCUMENT_ROOT */ $loc = preg_replace('`^\.\.?/`', "", $loc); if (is_null($priority)){ $priority = $this->defPriority; } if (is_null($changefreq)){ $changefreq = $this->defChangeFreq; } if (file_exists(DOCROOT.$loc)) { $this->staticPages[] = array ( "loc" => htmlentities($loc), "lastmod" => date("Y-m-d",filemtime(DOCROOT.$loc)), "priority" => $priority, "changefreq" => $changefreq ); } } function addDirectory($dir, $priority=NULL, $changefreq=NULL) { /* * Constructs an absolute-relative URL * for each file in the directory. */ $dir = preg_replace('`^\.\.?/`', "", $dir); $dir = preg_replace('`/$`', "", $dir); foreach (scandir(DOCROOT.$dir) as $value) { if ($value != "." && $value != ".." && is_file(DOCROOT.$dir."/".$value)){ $this->addStaticPage($dir."/".$value); } } } function implodeKeysWithValues($glue, $keys) { if (!is_array($keys) && empty($keys)){ return; } foreach ($keys as $key => $value) { if (isset($return)){ $return .= "&"; } $return .= $key.$glue.$keys[$key]; } return "?".$return; } function genXMLData() { $start = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<urlset xmlns=\"sitemaps.org/schemas/sitemap/0.9/;; $body .= "\t<url>\n"; $body .= "\t\t<loc>".SITEURL."</loc>\n"; $body .= "\t\t<priority>0.9</priority>\n"; $body .= "\t\t<changefreq>weekly</changefreq>\n"; $body .= "\t</url>\n"; if (is_array($this->dynamicPages)) { foreach ($this->dynamicPages as $key => $value) { $body .= "\t<url>\n"; $body .= "\t\t<loc>".SITEURL.$this->dynamicPages[$key]['loc']."</loc>\n"; if (!empty($this->dynamicPages[$key]['lastmod'])){ $body .= "\t\t<lastmod>".$this->dynamicPages[$key]['lastmod']."</lastmod>\n"; } $body .= "\t\t<priority>".$this->dynamicPages[$key]['priority']."</priority>\n"; $body .= "\t\t<changefreq>".$this->dynamicPages[$key]['changefreq']."</changefreq>\n"; $body .= "\t</url>\n"; } } if (is_array($this->staticPages)) { foreach ($this->staticPages as $key => $value) { $body .= "\t<url>\n"; $body .= "\t\t<loc>".SITEURL.$this->staticPages[$key]['loc']."</loc>\n"; if (!empty($this->staticPages[$key]['lastmod'])){ $body .= "\t\t<lastmod>".$this->staticPages[$key]['lastmod']."</lastmod>\n"; } $body .= "\t\t<priority>".$this->staticPages[$key]['priority']."</priority>\n"; $body .= "\t\t<changefreq>".$this->staticPages[$key]['changefreq']."</changefreq>\n"; $body .= "\t</url>\n"; } } $end = "</urlset>\n"; return $start.$body.$end; } function renderXMLFile($path){ file_put_contents($path, $this->genXMLData()); }}?> Example Usage <?phprequire "sitemap.class.php";$sitemap = new sitemap(0.5, "monthly");$sitemap->addDirectory("news");$sitemap->addStaticPage("affiliates.html", 0.6, "weekly");$sitemap->addDynamicPage(NULL, array("index.php", "blog"), array("tag" => "PHP"), NULL, 0.7, "daily");$sitemap->genXMLData();?> The above code should, for example, output the following: <?xml version="1.0" encoding="UTF-8"?><urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9/; <url> <loc>http://yoursite/</loc> <priority>0.9</priority> <changefreq>weekly</changefreq> </url> <url> <loc>http://yoursite/index.php/blog/?tag=PHP</loc> <priority>0.7</priority> <changefreq>daily</changefreq> </url> <url> <loc>http://yoursite/news/somenews1.html</loc> <lastmod>2008-10-16</lastmod> <priority>0.5</priority> <changefreq>monthly</changefreq> </url> <url> <loc>http://yoursite/news/somenews2.html</loc> <lastmod>2008-11-16</lastmod> <priority>0.5</priority> <changefreq>monthly</changefreq> </url> <url> <loc>http://yoursite/affiliates.html</loc> <lastmod>2008-12-10</lastmod> <priority>0.6</priority> <changefreq>weekly</changefreq> </url> </urlset> If you use this class, you may report any problems here.
-
So i've been doing a lot of reading concerning arguments for the case of God—be it ontological, teleological or cosmological—and since Wikipedia tends to have arguments for both sides, that is where most of my reading has been. (I like viewing other people's arguments to see where mine could use some work and to see if theirs contain flaws.) I've done other research outside of Wikipedia concerning the beginning of time and space and the Big Bang theory, too. From my understanding of it, the Big Bang theory asserts or implies that there was literally nothing before it, as it is said that space and time came into existence at that very moment. Concerning cosmological arguments, i shall quote a certain statement found on Wikipedia: That brings up a dilemma: is energy created or not? Or, perhaps, how can something just be (i.e. not created but always existent) though time and space had a beginning? The conversion from nothing into something is known as creation. So either the Big Bang theory is automatically refuted, or energy can be created. If i am missing any detail concerning this, i'ma leave it up to the people at Xisto to point that out to me. But if all information here is correct, then which one is it: was energy created or not?