win32 to unix line delimiters changed
authorRoland Häder <roland@mxchange.org>
Wed, 30 Jan 2008 21:24:54 +0000 (21:24 +0000)
committerRoland Häder <roland@mxchange.org>
Wed, 30 Jan 2008 21:24:54 +0000 (21:24 +0000)
552 files changed:
0.2.1/admin.php
0.2.1/agb.php
0.2.1/beg.php
0.2.1/birthday_confirm.php
0.2.1/click.php
0.2.1/confirm.php
0.2.1/css.php
0.2.1/doubler.php
0.2.1/img.php
0.2.1/inc/autopurge.php
0.2.1/inc/config.php
0.2.1/inc/databases.php
0.2.1/inc/db/lib-mysql3.php
0.2.1/inc/db/lib.php
0.2.1/inc/doubler_send.php
0.2.1/inc/extensions.php
0.2.1/inc/extensions/ext-active.php
0.2.1/inc/extensions/ext-admins.php
0.2.1/inc/extensions/ext-admintheme1.php
0.2.1/inc/extensions/ext-admintheme_default.php
0.2.1/inc/extensions/ext-autopurge.php
0.2.1/inc/extensions/ext-bank.php
0.2.1/inc/extensions/ext-beg.php
0.2.1/inc/extensions/ext-birthday.php
0.2.1/inc/extensions/ext-bonus.php
0.2.1/inc/extensions/ext-cache.php
0.2.1/inc/extensions/ext-country.php
0.2.1/inc/extensions/ext-demo.php
0.2.1/inc/extensions/ext-doubler.php
0.2.1/inc/extensions/ext-holiday.php
0.2.1/inc/extensions/ext-html_mail.php
0.2.1/inc/extensions/ext-mailid.php
0.2.1/inc/extensions/ext-maintenance.php
0.2.1/inc/extensions/ext-mediadata.php
0.2.1/inc/extensions/ext-mods.php
0.2.1/inc/extensions/ext-mydata.php
0.2.1/inc/extensions/ext-newsletter.php
0.2.1/inc/extensions/ext-nickname.php
0.2.1/inc/extensions/ext-online.php
0.2.1/inc/extensions/ext-optimize.php
0.2.1/inc/extensions/ext-order.php
0.2.1/inc/extensions/ext-other.php
0.2.1/inc/extensions/ext-payout.php
0.2.1/inc/extensions/ext-profile.php
0.2.1/inc/extensions/ext-rallye.php
0.2.1/inc/extensions/ext-register.php
0.2.1/inc/extensions/ext-repair.php
0.2.1/inc/extensions/ext-rewrite.php
0.2.1/inc/extensions/ext-sql_patches.php
0.2.1/inc/extensions/ext-support.php
0.2.1/inc/extensions/ext-task.php
0.2.1/inc/extensions/ext-theme.php
0.2.1/inc/extensions/ext-top10.php
0.2.1/inc/extensions/ext-transfer.php
0.2.1/inc/extensions/ext-user.php
0.2.1/inc/extensions/ext-wernis.php
0.2.1/inc/fatal_errors.php
0.2.1/inc/footer.php
0.2.1/inc/functions.php
0.2.1/inc/gen_mediadata.php
0.2.1/inc/gen_sql_patches.php
0.2.1/inc/header.php
0.2.1/inc/install-inc.php
0.2.1/inc/language.php
0.2.1/inc/language/active_de.php
0.2.1/inc/language/admins_de.php
0.2.1/inc/language/autopurge_de.php
0.2.1/inc/language/bank_de.php
0.2.1/inc/language/beg_de.php
0.2.1/inc/language/birthday_de.php
0.2.1/inc/language/bonus_de.php
0.2.1/inc/language/cache_de.php
0.2.1/inc/language/country_de.php
0.2.1/inc/language/de.php
0.2.1/inc/language/doubler_de.php
0.2.1/inc/language/en.php
0.2.1/inc/language/holiday_de.php
0.2.1/inc/language/html_mail_de.php
0.2.1/inc/language/install_de.php
0.2.1/inc/language/mailid_de.php
0.2.1/inc/language/maintenance_de.php
0.2.1/inc/language/mediadata_de.php
0.2.1/inc/language/mods_de.php
0.2.1/inc/language/newsletter_de.php
0.2.1/inc/language/nickname_de.php
0.2.1/inc/language/online_de.php
0.2.1/inc/language/optimize_de.php
0.2.1/inc/language/order_de.php
0.2.1/inc/language/other_de.php
0.2.1/inc/language/payout_de.php
0.2.1/inc/language/pro_de.php
0.2.1/inc/language/rallye_de.php
0.2.1/inc/language/register_de.php
0.2.1/inc/language/repair_de.php
0.2.1/inc/language/rewrite_de.php
0.2.1/inc/language/support_de.php
0.2.1/inc/language/task_de.php
0.2.1/inc/language/theme_de.php
0.2.1/inc/language/top10_de.php
0.2.1/inc/language/transfer_de.php
0.2.1/inc/language/user_de.php
0.2.1/inc/language/wernis_de.php
0.2.1/inc/libs/admins_functions.php
0.2.1/inc/libs/autopurge_functions.php
0.2.1/inc/libs/bonus_functions.php
0.2.1/inc/libs/cache_functions.php
0.2.1/inc/libs/country_functions.php
0.2.1/inc/libs/doubler_functions.php
0.2.1/inc/libs/holiday_functions.php
0.2.1/inc/libs/html_mail_functions.php
0.2.1/inc/libs/mediadata_functions.php
0.2.1/inc/libs/newsletter_functions.php
0.2.1/inc/libs/nickname_functions.php
0.2.1/inc/libs/optimize_functions.php
0.2.1/inc/libs/order_functions.php
0.2.1/inc/libs/output_functions.php
0.2.1/inc/libs/payout_functions.php
0.2.1/inc/libs/rallye_functions.php
0.2.1/inc/libs/register_functions.php
0.2.1/inc/libs/rewrite_functions.php
0.2.1/inc/libs/security_functions.php
0.2.1/inc/libs/task_functions.php
0.2.1/inc/libs/transfer_functions.php
0.2.1/inc/libs/user_functions.php
0.2.1/inc/libs/wernis_functions.php
0.2.1/inc/load_cache.php
0.2.1/inc/load_extensions.php
0.2.1/inc/mails/_mails.php
0.2.1/inc/mails/beg_mails.php
0.2.1/inc/mails/birthday_mails.php
0.2.1/inc/mails/bonus_mails.php
0.2.1/inc/modules/admin.php
0.2.1/inc/modules/admin/action-admins.php
0.2.1/inc/modules/admin/action-bank.php
0.2.1/inc/modules/admin/action-country.php
0.2.1/inc/modules/admin/action-doubler.php
0.2.1/inc/modules/admin/action-email.php
0.2.1/inc/modules/admin/action-holiday.php
0.2.1/inc/modules/admin/action-login.php
0.2.1/inc/modules/admin/action-logout.php
0.2.1/inc/modules/admin/action-menu.php
0.2.1/inc/modules/admin/action-misc.php
0.2.1/inc/modules/admin/action-mods.php
0.2.1/inc/modules/admin/action-newsletter.php
0.2.1/inc/modules/admin/action-payouts.php
0.2.1/inc/modules/admin/action-rallye.php
0.2.1/inc/modules/admin/action-repair.php
0.2.1/inc/modules/admin/action-setup.php
0.2.1/inc/modules/admin/action-stats.php
0.2.1/inc/modules/admin/action-task.php
0.2.1/inc/modules/admin/action-theme.php
0.2.1/inc/modules/admin/action-transfer.php
0.2.1/inc/modules/admin/action-user.php
0.2.1/inc/modules/admin/action-wernis.php
0.2.1/inc/modules/admin/admin-inc.php
0.2.1/inc/modules/admin/overview-inc.php
0.2.1/inc/modules/admin/what-add_bank_package.php
0.2.1/inc/modules/admin/what-add_guestnl_cat.php
0.2.1/inc/modules/admin/what-add_points.php
0.2.1/inc/modules/admin/what-add_rallye.php
0.2.1/inc/modules/admin/what-admin_add.php
0.2.1/inc/modules/admin/what-adminedit.php
0.2.1/inc/modules/admin/what-admins_add.php
0.2.1/inc/modules/admin/what-admins_contact.php
0.2.1/inc/modules/admin/what-admins_contct.php
0.2.1/inc/modules/admin/what-admins_edit.php
0.2.1/inc/modules/admin/what-admins_mails.php
0.2.1/inc/modules/admin/what-autopurge.php
0.2.1/inc/modules/admin/what-bonus.php
0.2.1/inc/modules/admin/what-cache_stats.php
0.2.1/inc/modules/admin/what-chk_regs.php
0.2.1/inc/modules/admin/what-config_active.php
0.2.1/inc/modules/admin/what-config_admin.php
0.2.1/inc/modules/admin/what-config_admins.php
0.2.1/inc/modules/admin/what-config_autopurge.php
0.2.1/inc/modules/admin/what-config_beg.php
0.2.1/inc/modules/admin/what-config_birthday.php
0.2.1/inc/modules/admin/what-config_bonus.php
0.2.1/inc/modules/admin/what-config_cache.php
0.2.1/inc/modules/admin/what-config_cats.php
0.2.1/inc/modules/admin/what-config_doubler.php
0.2.1/inc/modules/admin/what-config_email.php
0.2.1/inc/modules/admin/what-config_extensions.php
0.2.1/inc/modules/admin/what-config_holiday.php
0.2.1/inc/modules/admin/what-config_home.php
0.2.1/inc/modules/admin/what-config_mediadata.php
0.2.1/inc/modules/admin/what-config_mods.php
0.2.1/inc/modules/admin/what-config_newsletter.php
0.2.1/inc/modules/admin/what-config_nickname.php
0.2.1/inc/modules/admin/what-config_order.php
0.2.1/inc/modules/admin/what-config_other.php
0.2.1/inc/modules/admin/what-config_payouts.php
0.2.1/inc/modules/admin/what-config_points.php
0.2.1/inc/modules/admin/what-config_rallye_prices.php
0.2.1/inc/modules/admin/what-config_refid.php
0.2.1/inc/modules/admin/what-config_reg.php
0.2.1/inc/modules/admin/what-config_register.php
0.2.1/inc/modules/admin/what-config_register2.php
0.2.1/inc/modules/admin/what-config_rewrite.php
0.2.1/inc/modules/admin/what-config_secure.php
0.2.1/inc/modules/admin/what-config_stats.php
0.2.1/inc/modules/admin/what-config_title.php
0.2.1/inc/modules/admin/what-config_top10.php
0.2.1/inc/modules/admin/what-config_transfer.php
0.2.1/inc/modules/admin/what-config_user.php
0.2.1/inc/modules/admin/what-config_wernis.php
0.2.1/inc/modules/admin/what-del_email.php
0.2.1/inc/modules/admin/what-del_holiday.php
0.2.1/inc/modules/admin/what-del_task.php
0.2.1/inc/modules/admin/what-del_transfer.php
0.2.1/inc/modules/admin/what-del_user.php
0.2.1/inc/modules/admin/what-edit_emails.php
0.2.1/inc/modules/admin/what-edit_user.php
0.2.1/inc/modules/admin/what-email_archiv.php
0.2.1/inc/modules/admin/what-email_details.php
0.2.1/inc/modules/admin/what-email_stats.php
0.2.1/inc/modules/admin/what-extensions.php
0.2.1/inc/modules/admin/what-guest_add.php
0.2.1/inc/modules/admin/what-guestedit.php
0.2.1/inc/modules/admin/what-holiday_list.php
0.2.1/inc/modules/admin/what-holiday_remove.php
0.2.1/inc/modules/admin/what-list_autopurge.php
0.2.1/inc/modules/admin/what-list_bank_package.php
0.2.1/inc/modules/admin/what-list_beg.php
0.2.1/inc/modules/admin/what-list_bonus.php
0.2.1/inc/modules/admin/what-list_cats.php
0.2.1/inc/modules/admin/what-list_country.php
0.2.1/inc/modules/admin/what-list_doubler.php
0.2.1/inc/modules/admin/what-list_holiday.php
0.2.1/inc/modules/admin/what-list_links.php
0.2.1/inc/modules/admin/what-list_newsletter.php
0.2.1/inc/modules/admin/what-list_norefs.php
0.2.1/inc/modules/admin/what-list_payouts.php
0.2.1/inc/modules/admin/what-list_rallyes.php
0.2.1/inc/modules/admin/what-list_refs.php
0.2.1/inc/modules/admin/what-list_task.php
0.2.1/inc/modules/admin/what-list_transfer.php
0.2.1/inc/modules/admin/what-list_unconfirmed.php
0.2.1/inc/modules/admin/what-list_user.php
0.2.1/inc/modules/admin/what-list_wernis.php
0.2.1/inc/modules/admin/what-lock_user.php
0.2.1/inc/modules/admin/what-logs.php
0.2.1/inc/modules/admin/what-maintenance.php
0.2.1/inc/modules/admin/what-mem_add.php
0.2.1/inc/modules/admin/what-memedit.php
0.2.1/inc/modules/admin/what-newsletter.php
0.2.1/inc/modules/admin/what-optimize.php
0.2.1/inc/modules/admin/what-overview.php
0.2.1/inc/modules/admin/what-payments.php
0.2.1/inc/modules/admin/what-refbanner.php
0.2.1/inc/modules/admin/what-repair_amenu.php
0.2.1/inc/modules/admin/what-repair_amnu.php
0.2.1/inc/modules/admin/what-repair_cats.php
0.2.1/inc/modules/admin/what-repair_gmenu.php
0.2.1/inc/modules/admin/what-repair_gmnu.php
0.2.1/inc/modules/admin/what-repair_mmenu.php
0.2.1/inc/modules/admin/what-repair_mmnu.php
0.2.1/inc/modules/admin/what-send_bonus.php
0.2.1/inc/modules/admin/what-send_newsletter.php
0.2.1/inc/modules/admin/what-stats.php
0.2.1/inc/modules/admin/what-stats_mods.php
0.2.1/inc/modules/admin/what-sub_points.php
0.2.1/inc/modules/admin/what-theme_check.php
0.2.1/inc/modules/admin/what-theme_edit.php
0.2.1/inc/modules/admin/what-theme_import.php
0.2.1/inc/modules/admin/what-unlock_emails.php
0.2.1/inc/modules/admin/what-updates.php
0.2.1/inc/modules/admin/what-usage.php
0.2.1/inc/modules/admin/what-user_online.php
0.2.1/inc/modules/admin/what-usr_online.php
0.2.1/inc/modules/chk_login.php
0.2.1/inc/modules/frameset.php
0.2.1/inc/modules/frametester.php
0.2.1/inc/modules/guest/action-admin.php
0.2.1/inc/modules/guest/action-main.php
0.2.1/inc/modules/guest/action-members.php
0.2.1/inc/modules/guest/action-online.php
0.2.1/inc/modules/guest/action-themes.php
0.2.1/inc/modules/guest/what-active.php
0.2.1/inc/modules/guest/what-admin.php
0.2.1/inc/modules/guest/what-agb.php
0.2.1/inc/modules/guest/what-beg.php
0.2.1/inc/modules/guest/what-confirm.php
0.2.1/inc/modules/guest/what-doubler.php
0.2.1/inc/modules/guest/what-impressum.php
0.2.1/inc/modules/guest/what-infos.php
0.2.1/inc/modules/guest/what-login.php
0.2.1/inc/modules/guest/what-mediadata.php
0.2.1/inc/modules/guest/what-my_weblog.php
0.2.1/inc/modules/guest/what-rallyes.php
0.2.1/inc/modules/guest/what-register.php
0.2.1/inc/modules/guest/what-stats.php
0.2.1/inc/modules/guest/what-top10.php
0.2.1/inc/modules/guest/what-welcome.php
0.2.1/inc/modules/guest/what-wernis_portal.php
0.2.1/inc/modules/index.php
0.2.1/inc/modules/loader.php
0.2.1/inc/modules/login.php
0.2.1/inc/modules/member/action-account.php
0.2.1/inc/modules/member/action-bank.php
0.2.1/inc/modules/member/action-extras.php
0.2.1/inc/modules/member/action-logout.php
0.2.1/inc/modules/member/action-main.php
0.2.1/inc/modules/member/action-order.php
0.2.1/inc/modules/member/action-rals.php
0.2.1/inc/modules/member/action-stats.php
0.2.1/inc/modules/member/action-themes.php
0.2.1/inc/modules/member/what-bank_create.php
0.2.1/inc/modules/member/what-bank_deposit.php
0.2.1/inc/modules/member/what-bank_infos.php
0.2.1/inc/modules/member/what-bank_output.php
0.2.1/inc/modules/member/what-bank_withdraw.php
0.2.1/inc/modules/member/what-beg.php
0.2.1/inc/modules/member/what-beg2.php
0.2.1/inc/modules/member/what-bonus.php
0.2.1/inc/modules/member/what-categories.php
0.2.1/inc/modules/member/what-doubler.php
0.2.1/inc/modules/member/what-guest.php
0.2.1/inc/modules/member/what-holiday.php
0.2.1/inc/modules/member/what-html_mail.php
0.2.1/inc/modules/member/what-logout.php
0.2.1/inc/modules/member/what-mydata.php
0.2.1/inc/modules/member/what-newsletter.php
0.2.1/inc/modules/member/what-nickname.php
0.2.1/inc/modules/member/what-order.php
0.2.1/inc/modules/member/what-payout.php
0.2.1/inc/modules/member/what-points.php
0.2.1/inc/modules/member/what-rallyes.php
0.2.1/inc/modules/member/what-reflinks.php
0.2.1/inc/modules/member/what-stats.php
0.2.1/inc/modules/member/what-support.php
0.2.1/inc/modules/member/what-themes.php
0.2.1/inc/modules/member/what-transfer.php
0.2.1/inc/modules/member/what-unconfirmed.php
0.2.1/inc/modules/member/what-welcome.php
0.2.1/inc/modules/member/what-wernis.php
0.2.1/inc/modules/order.php
0.2.1/inc/modules/welcome.php
0.2.1/inc/monthly/monthly_beg.php
0.2.1/inc/monthly/monthly_bonus.php
0.2.1/inc/monthly/monthly_newsletter.php
0.2.1/inc/monthly_newsletter.php
0.2.1/inc/mysql-connect.php
0.2.1/inc/mysql-manager.php
0.2.1/inc/patch-system.php
0.2.1/inc/phpmailer/ChangeLog.txt
0.2.1/inc/phpmailer/class.phpmailer.php
0.2.1/inc/phpmailer/class.pop3.php
0.2.1/inc/phpmailer/class.smtp.php
0.2.1/inc/phpmailer/codeworxtech.html
0.2.1/inc/phpmailer/docs/extending.html
0.2.1/inc/phpmailer/docs/faq.html
0.2.1/inc/phpmailer/docs/pop3_article.txt
0.2.1/inc/phpmailer/docs/use_gmail.txt
0.2.1/inc/phpmailer/examples/contents.html
0.2.1/inc/phpmailer/examples/index.html
0.2.1/inc/phpmailer/examples/pop3_before_smtp_test.php
0.2.1/inc/phpmailer/examples/test1.php
0.2.1/inc/phpmailer/language/phpmailer.lang-br.php
0.2.1/inc/phpmailer/language/phpmailer.lang-ca.php
0.2.1/inc/phpmailer/language/phpmailer.lang-cz.php
0.2.1/inc/phpmailer/language/phpmailer.lang-de.php
0.2.1/inc/phpmailer/language/phpmailer.lang-dk.php
0.2.1/inc/phpmailer/language/phpmailer.lang-en.php
0.2.1/inc/phpmailer/language/phpmailer.lang-es.php
0.2.1/inc/phpmailer/language/phpmailer.lang-et.php
0.2.1/inc/phpmailer/language/phpmailer.lang-fi.php
0.2.1/inc/phpmailer/language/phpmailer.lang-fo.php
0.2.1/inc/phpmailer/language/phpmailer.lang-fr.php
0.2.1/inc/phpmailer/language/phpmailer.lang-hu.php
0.2.1/inc/phpmailer/language/phpmailer.lang-it.php
0.2.1/inc/phpmailer/language/phpmailer.lang-ja.php
0.2.1/inc/phpmailer/language/phpmailer.lang-nl.php
0.2.1/inc/phpmailer/language/phpmailer.lang-no.php
0.2.1/inc/phpmailer/language/phpmailer.lang-pl.php
0.2.1/inc/phpmailer/language/phpmailer.lang-ro.php
0.2.1/inc/phpmailer/language/phpmailer.lang-ru.php
0.2.1/inc/phpmailer/language/phpmailer.lang-se.php
0.2.1/inc/phpmailer/language/phpmailer.lang-tr.php
0.2.1/inc/phpmailer/phpdoc/media/banner.css
0.2.1/inc/phpmailer/phpdoc/media/stylesheet.css
0.2.1/inc/phpmailer/test/phpmailer_test.php
0.2.1/inc/phpmailer/test/phpunit.php
0.2.1/inc/pool-update.php
0.2.1/inc/profile-updte.php
0.2.1/inc/rdf.class.php
0.2.1/inc/reset/reset_beg.php
0.2.1/inc/reset/reset_bonus.php
0.2.1/inc/reset/reset_daily.php
0.2.1/inc/reset/reset_engine.php
0.2.1/inc/reset/reset_holiday.php
0.2.1/inc/security.php
0.2.1/inc/session.php
0.2.1/inc/sql_error.php
0.2.1/inc/stats_bonus.php
0.2.1/inc/stylesheet.php
0.2.1/inc/theme-manager.php
0.2.1/index.php
0.2.1/install.php
0.2.1/lead-confirm.php
0.2.1/login.php
0.2.1/mailid.php
0.2.1/mailid_top.php
0.2.1/modules.php
0.2.1/ref.php
0.2.1/robots.txt
0.2.1/show_bonus.php
0.2.1/templates/de/emails/add-points.tpl
0.2.1/templates/de/emails/admin-del_links.tpl
0.2.1/templates/de/emails/admin/admin_autopurge_del_mails.tpl
0.2.1/templates/de/emails/admin/admin_autopurge_delete.tpl
0.2.1/templates/de/emails/admin/admin_autopurge_inactive.tpl
0.2.1/templates/de/emails/admin/admin_autopurge_points.tpl
0.2.1/templates/de/emails/admin/admin_autopurge_tsks.tpl
0.2.1/templates/de/emails/admin/admin_autopurge_turbo.tpl
0.2.1/templates/de/emails/admin/admin_autopurge_unconfirmed.tpl
0.2.1/templates/de/emails/admin/admin_holiday_deactivated.tpl
0.2.1/templates/de/emails/admin/admin_holiday_request.tpl
0.2.1/templates/de/emails/admin/admin_holiday_unlock.tpl
0.2.1/templates/de/emails/admin/admin_mydata_notify.tpl
0.2.1/templates/de/emails/admin/admin_new_ext.tpl
0.2.1/templates/de/emails/admin/admin_newsletter_request.tpl
0.2.1/templates/de/emails/admin/admin_newsletter_reset.tpl
0.2.1/templates/de/emails/admin/admin_payout_request.tpl
0.2.1/templates/de/emails/admin/admin_payout_request_banner.tpl
0.2.1/templates/de/emails/admin/admin_rallye_expired.tpl
0.2.1/templates/de/emails/admin/admin_rallye_expired_no.tpl
0.2.1/templates/de/emails/admin/admin_rallye_no_notify.tpl
0.2.1/templates/de/emails/admin/admin_rallye_notify.tpl
0.2.1/templates/de/emails/admin/admin_rallye_purged.tpl
0.2.1/templates/de/emails/admin/admin_support-ordr.tpl
0.2.1/templates/de/emails/admin/admin_support-reflink.tpl
0.2.1/templates/de/emails/admin/admin_support-unconfirmed.tpl
0.2.1/templates/de/emails/admin/admin_transfer_ap.tpl
0.2.1/templates/de/emails/admin/admin_transfer_points.tpl
0.2.1/templates/de/emails/admin/admin_wernis_request.tpl
0.2.1/templates/de/emails/admins/admins_mail_contct_admin.tpl
0.2.1/templates/de/emails/admins/admins_msg_contct_admin.tpl
0.2.1/templates/de/emails/admins_mail_contact_admin.tpl
0.2.1/templates/de/emails/admins_msg_contact_admin.tpl
0.2.1/templates/de/emails/back-admin.tpl
0.2.1/templates/de/emails/back-member.tpl
0.2.1/templates/de/emails/beg/beg_di_notify.tpl
0.2.1/templates/de/emails/beg/beg_en_notify.tpl
0.2.1/templates/de/emails/beg/beg_en_notify_body.tpl
0.2.1/templates/de/emails/bonus-mail.tpl
0.2.1/templates/de/emails/bonus/bonus_di_notify.tpl
0.2.1/templates/de/emails/bonus/bonus_en_notify.tpl
0.2.1/templates/de/emails/bonus/bonus_en_notify_body.tpl
0.2.1/templates/de/emails/confirm-member.tpl
0.2.1/templates/de/emails/confirm-referral.tpl
0.2.1/templates/de/emails/del-user.tpl
0.2.1/templates/de/emails/done-admin.tpl
0.2.1/templates/de/emails/done-member.tpl
0.2.1/templates/de/emails/guest/guest_request_confirm.tpl
0.2.1/templates/de/emails/header.tpl
0.2.1/templates/de/emails/lock-user.tpl
0.2.1/templates/de/emails/member/member_autopurge_delete.tpl
0.2.1/templates/de/emails/member/member_autopurge_inactive.tpl
0.2.1/templates/de/emails/member/member_autopurge_points.tpl
0.2.1/templates/de/emails/member/member_autopurge_unconfirmed.tpl
0.2.1/templates/de/emails/member/member_beg.tpl
0.2.1/templates/de/emails/member/member_birthday.tpl
0.2.1/templates/de/emails/member/member_birthday_confirm.tpl
0.2.1/templates/de/emails/member/member_bonus.tpl
0.2.1/templates/de/emails/member/member_contct.tpl
0.2.1/templates/de/emails/member/member_doubler.tpl
0.2.1/templates/de/emails/member/member_holiday_activated.tpl
0.2.1/templates/de/emails/member/member_holiday_removed.tpl
0.2.1/templates/de/emails/member/member_holiday_request.tpl
0.2.1/templates/de/emails/member/member_holiday_unlock.tpl
0.2.1/templates/de/emails/member/member_mydata_notify.tpl
0.2.1/templates/de/emails/member/member_newsletter_done.tpl
0.2.1/templates/de/emails/member/member_newsletter_request.tpl
0.2.1/templates/de/emails/member/member_newsletter_reset.tpl
0.2.1/templates/de/emails/member/member_payout_accepted.tpl
0.2.1/templates/de/emails/member/member_payout_rejected.tpl
0.2.1/templates/de/emails/member/member_payout_request.tpl
0.2.1/templates/de/emails/member/member_payout_request_banner.tpl
0.2.1/templates/de/emails/member/member_rallye_expired.tpl
0.2.1/templates/de/emails/member/member_rallye_expired_bronce.tpl
0.2.1/templates/de/emails/member/member_rallye_expired_gold.tpl
0.2.1/templates/de/emails/member/member_rallye_expired_silver.tpl
0.2.1/templates/de/emails/member/member_rallye_notify.tpl
0.2.1/templates/de/emails/member/member_stats_bonus.tpl
0.2.1/templates/de/emails/member/member_support-order.tpl
0.2.1/templates/de/emails/member/member_support-ordr.tpl
0.2.1/templates/de/emails/member/member_support-reflink.tpl
0.2.1/templates/de/emails/member/member_support-unconfirmed.tpl
0.2.1/templates/de/emails/member/member_transfer_recipient.tpl
0.2.1/templates/de/emails/member/member_transfer_sender.tpl
0.2.1/templates/de/emails/member/member_wernis_accepted.tpl
0.2.1/templates/de/emails/member/member_wernis_rejected.tpl
0.2.1/templates/de/emails/member/member_wernis_request.tpl
0.2.1/templates/de/emails/new-pass.tpl
0.2.1/templates/de/emails/newsletter.tpl
0.2.1/templates/de/emails/newsletter_html.tpl
0.2.1/templates/de/emails/normal-mail.tpl
0.2.1/templates/de/emails/order-accept.tpl
0.2.1/templates/de/emails/order-admin.tpl
0.2.1/templates/de/emails/order-deleted.tpl
0.2.1/templates/de/emails/order-member.tpl
0.2.1/templates/de/emails/order-reject.tpl
0.2.1/templates/de/emails/profile-updte.tpl
0.2.1/templates/de/emails/register-admin.tpl
0.2.1/templates/de/emails/register-member.tpl
0.2.1/templates/de/emails/sub-points.tpl
0.2.1/templates/de/emails/unlock-user.tpl
0.2.1/templates/de/html/admin/admin_list_user_sort_form.tpl
0.2.1/templates/de/html/guest/guest_stats_member.tpl
0.2.1/templates/de/html/header.tpl
0.2.1/templates/de/html/index_forward.tpl
0.2.1/templates/de/html/loader.tpl
0.2.1/templates/de/html/login_failed_js.tpl
0.2.1/templates/de/html/mailid/mailid_timer.tpl
0.2.1/templates/de/html/member/member_login_js.tpl
0.2.1/templates/de/html/member/member_reflinks_row.tpl
0.2.1/templates/de/html/member/member_support_form.tpl
0.2.1/theme/business/css/active.css
0.2.1/theme/business/css/beg.css
0.2.1/theme/business/css/bonus.css
0.2.1/theme/business/css/doubler.css
0.2.1/theme/business/css/general.css
0.2.1/theme/business/css/install.css
0.2.1/theme/business/css/register.css
0.2.1/theme/business/css/top10.css
0.2.1/theme/business/css/transfer.css
0.2.1/theme/business/theme.php
0.2.1/theme/default/css/active.css
0.2.1/theme/default/css/beg.css
0.2.1/theme/default/css/bonus.css
0.2.1/theme/default/css/doubler.css
0.2.1/theme/default/css/general.css
0.2.1/theme/default/css/install.css
0.2.1/theme/default/css/register.css
0.2.1/theme/default/css/top10.css
0.2.1/theme/default/css/transfer.css
0.2.1/theme/default/theme.php
0.2.1/theme/desert/css/active.css
0.2.1/theme/desert/css/beg.css
0.2.1/theme/desert/css/bonus.css
0.2.1/theme/desert/css/doubler.css
0.2.1/theme/desert/css/general.css
0.2.1/theme/desert/css/help.css
0.2.1/theme/desert/css/install.css
0.2.1/theme/desert/css/paidlinks.css
0.2.1/theme/desert/css/register.css
0.2.1/theme/desert/css/sponsor.css
0.2.1/theme/desert/css/top10.css
0.2.1/theme/desert/css/transfer.css
0.2.1/theme/desert/theme.php
0.2.1/view.php

index 2c61dc7931e1dca498ef63ba75e281763e349588..2320674c5e581198db2893ec6701faa650175d6c 100644 (file)
@@ -1,63 +1,63 @@
-<?php\r
-/************************************************************************\r
- * MXChange v0.2.1                                    Start: 03/27/2004 *\r
- * ===============                              Last change: 04/26/2004 *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * File              : admin.php                                        *\r
- * -------------------------------------------------------------------- *\r
- * Short description : Administration area                              *\r
- * -------------------------------------------------------------------- *\r
- * Kurzbeschreibung  : Administrationsbereich                           *\r
- * -------------------------------------------------------------------- *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * Copyright (c) 2003 - 2008 by Roland Haeder                           *\r
- * For more information visit: http://www.mxchange.org                  *\r
- *                                                                      *\r
- * This program is free software; you can redistribute it and/or modify *\r
- * it under the terms of the GNU General Public License as published by *\r
- * the Free Software Foundation; either version 2 of the License, or    *\r
- * (at your option) any later version.                                  *\r
- *                                                                      *\r
- * This program is distributed in the hope that it will be useful,      *\r
- * but WITHOUT ANY WARRANTY; without even the implied warranty of       *\r
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *\r
- * GNU General Public License for more details.                         *\r
- *                                                                      *\r
- * You should have received a copy of the GNU General Public License    *\r
- * along with this program; if not, write to the Free Software          *\r
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *\r
- * MA  02110-1301  USA                                                  *\r
- ************************************************************************/\r
-\r
-// Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )\r
-require_once("inc/libs/security_functions.php");\r
-\r
-// Init "action" and "what"\r
-global $what, $action;\r
-$GLOBALS['what'] = ""; $GLOBALS['action'] = "";\r
-if (!empty($_GET['action']))   $GLOBALS['action']      = secureString($_GET['action']);\r
-if (!empty($_GET['what']))             $GLOBALS['what']        = secureString($_GET['what']);\r
-\r
-// Set module\r
-$GLOBALS['module'] = "admin"; $CSS = -1;\r
-\r
-// Load the required file(s)\r
-require ("inc/config.php");\r
-\r
-// Is the script installed?\r
-if (defined('mxchange_installed') && (mxchange_installed))\r
-{\r
-       // Simply redirect... :-)\r
-       LOAD_URL(URL."/modules.php?module=admin&amp;action=login");\r
-       // Redirection should be done here\r
-}\r
- else\r
-{\r
-       // You have to configure first!\r
-       LOAD_URL(URL."/install.php");\r
-}\r
-\r
-// Really all done here... ;-)\r
-?>\r
+<?php
+/************************************************************************
+ * MXChange v0.2.1                                    Start: 03/27/2004 *
+ * ===============                              Last change: 04/26/2004 *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * File              : admin.php                                        *
+ * -------------------------------------------------------------------- *
+ * Short description : Administration area                              *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung  : Administrationsbereich                           *
+ * -------------------------------------------------------------------- *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2008 by Roland Haeder                           *
+ * For more information visit: http://www.mxchange.org                  *
+ *                                                                      *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or    *
+ * (at your option) any later version.                                  *
+ *                                                                      *
+ * This program is distributed in the hope that it will be useful,      *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of       *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *
+ * GNU General Public License for more details.                         *
+ *                                                                      *
+ * You should have received a copy of the GNU General Public License    *
+ * along with this program; if not, write to the Free Software          *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
+ * MA  02110-1301  USA                                                  *
+ ************************************************************************/
+
+// Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
+require_once("inc/libs/security_functions.php");
+
+// Init "action" and "what"
+global $what, $action;
+$GLOBALS['what'] = ""; $GLOBALS['action'] = "";
+if (!empty($_GET['action']))   $GLOBALS['action']      = secureString($_GET['action']);
+if (!empty($_GET['what']))             $GLOBALS['what']        = secureString($_GET['what']);
+
+// Set module
+$GLOBALS['module'] = "admin"; $CSS = -1;
+
+// Load the required file(s)
+require ("inc/config.php");
+
+// Is the script installed?
+if (defined('mxchange_installed') && (mxchange_installed))
+{
+       // Simply redirect... :-)
+       LOAD_URL(URL."/modules.php?module=admin&amp;action=login");
+       // Redirection should be done here
+}
+ else
+{
+       // You have to configure first!
+       LOAD_URL(URL."/install.php");
+}
+
+// Really all done here... ;-)
+?>
index a165e96419d19b48a78dc0fab31cd3bd633fde60..a802e0c4014ef25fce24b648fddeb0b94a512cc8 100644 (file)
@@ -1,62 +1,62 @@
-<?php\r
-/************************************************************************\r
- * MXChange v0.2.1                                    Start: 11/27/2003 *\r
- * ===============                              Last change: 04/26/2004 *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * File              : agb.php                                          *\r
- * -------------------------------------------------------------------- *\r
- * Short description : Terms Of Usage link                              *\r
- * -------------------------------------------------------------------- *\r
- * Kurzbeschreibung  : Allgemeine Geschaeftsbedingungen                 *\r
- * -------------------------------------------------------------------- *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * Copyright (c) 2003 - 2008 by Roland Haeder                           *\r
- * For more information visit: http://www.mxchange.org                  *\r
- *                                                                      *\r
- * This program is free software; you can redistribute it and/or modify *\r
- * it under the terms of the GNU General Public License as published by *\r
- * the Free Software Foundation; either version 2 of the License, or    *\r
- * (at your option) any later version.                                  *\r
- *                                                                      *\r
- * This program is distributed in the hope that it will be useful,      *\r
- * but WITHOUT ANY WARRANTY; without even the implied warranty of       *\r
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *\r
- * GNU General Public License for more details.                         *\r
- *                                                                      *\r
- * You should have received a copy of the GNU General Public License    *\r
- * along with this program; if not, write to the Free Software          *\r
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *\r
- * MA  02110-1301  USA                                                  *\r
- ************************************************************************/\r
-\r
-// Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )\r
-require_once("inc/libs/security_functions.php");\r
-\r
-// Init "action" and "what"\r
-global $what, $action;\r
-$GLOBALS['what'] = ""; $GLOBALS['action'] = "";\r
-if (!empty($_GET['action'])) $GLOBALS['action'] = secureString($_GET['action']);\r
-if (!empty($_GET['what']))   $GLOBALS['what'] = secureString($_GET['what']);\r
-\r
-// Set module\r
-$GLOBALS['module'] = "agb"; $CSS = -1;\r
-\r
-// Load the required file(s)\r
-require ("inc/config.php");\r
-\r
-// Is the script installed?\r
-if (defined('mxchange_installed') && (mxchange_installed))\r
-{\r
-       // Simply redirect... :-)\r
-       LOAD_URL(URL."/modules.php?module=index&amp;what=agb");\r
-       // Redirection should be done here\r
-}\r
- else\r
-{\r
-       // You have to configure first!\r
-       LOAD_URL(URL."/install.php");\r
-}\r
-// Really all done here... ;-)\r
-?>\r
+<?php
+/************************************************************************
+ * MXChange v0.2.1                                    Start: 11/27/2003 *
+ * ===============                              Last change: 04/26/2004 *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * File              : agb.php                                          *
+ * -------------------------------------------------------------------- *
+ * Short description : Terms Of Usage link                              *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung  : Allgemeine Geschaeftsbedingungen                 *
+ * -------------------------------------------------------------------- *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2008 by Roland Haeder                           *
+ * For more information visit: http://www.mxchange.org                  *
+ *                                                                      *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or    *
+ * (at your option) any later version.                                  *
+ *                                                                      *
+ * This program is distributed in the hope that it will be useful,      *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of       *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *
+ * GNU General Public License for more details.                         *
+ *                                                                      *
+ * You should have received a copy of the GNU General Public License    *
+ * along with this program; if not, write to the Free Software          *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
+ * MA  02110-1301  USA                                                  *
+ ************************************************************************/
+
+// Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
+require_once("inc/libs/security_functions.php");
+
+// Init "action" and "what"
+global $what, $action;
+$GLOBALS['what'] = ""; $GLOBALS['action'] = "";
+if (!empty($_GET['action'])) $GLOBALS['action'] = secureString($_GET['action']);
+if (!empty($_GET['what']))   $GLOBALS['what'] = secureString($_GET['what']);
+
+// Set module
+$GLOBALS['module'] = "agb"; $CSS = -1;
+
+// Load the required file(s)
+require ("inc/config.php");
+
+// Is the script installed?
+if (defined('mxchange_installed') && (mxchange_installed))
+{
+       // Simply redirect... :-)
+       LOAD_URL(URL."/modules.php?module=index&amp;what=agb");
+       // Redirection should be done here
+}
+ else
+{
+       // You have to configure first!
+       LOAD_URL(URL."/install.php");
+}
+// Really all done here... ;-)
+?>
index b936b787ef49756c469993ced38221a8c2ca8b8a..9d5380cb8770979d499b1768242fbd637b8e339b 100644 (file)
-<?php\r
-/************************************************************************\r
- * MXChange v0.2.1                                    Start: 01/09/2005 *\r
- * ===============                              Last change: 01/09/2005 *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * File              : beg.php                                          *\r
- * -------------------------------------------------------------------- *\r
- * Short description : Beg link for members                             *\r
- * -------------------------------------------------------------------- *\r
- * Kurzbeschreibung  : Bettel-Link fuer Mitglieder                      *\r
- * -------------------------------------------------------------------- *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * Copyright (c) 2003 - 2008 by Roland Haeder                           *\r
- * For more information visit: http://www.mxchange.org                  *\r
- *                                                                      *\r
- * This program is free software; you can redistribute it and/or modify *\r
- * it under the terms of the GNU General Public License as published by *\r
- * the Free Software Foundation; either version 2 of the License, or    *\r
- * (at your option) any later version.                                  *\r
- *                                                                      *\r
- * This program is distributed in the hope that it will be useful,      *\r
- * but WITHOUT ANY WARRANTY; without even the implied warranty of       *\r
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *\r
- * GNU General Public License for more details.                         *\r
- *                                                                      *\r
- * You should have received a copy of the GNU General Public License    *\r
- * along with this program; if not, write to the Free Software          *\r
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *\r
- * MA  02110-1301  USA                                                  *\r
- ************************************************************************/\r
-\r
-// Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )\r
-require_once("inc/libs/security_functions.php");\r
-\r
-// Init "action" and "what"\r
-global $what, $action;\r
-$GLOBALS['what'] = ""; $GLOBALS['action'] = "";\r
-if (!empty($_GET['action'])) $GLOBALS['action'] = secureString($_GET['action']);\r
-if (!empty($_GET['what'])) $GLOBALS['what'] = secureString($_GET['what']);\r
-\r
-// Set module\r
-$GLOBALS['module'] = "beg";\r
-$GLOBALS['refid']  = 0;\r
-$CSS = -1;\r
-\r
-// Load the required file(s)\r
-require ("inc/config.php");\r
-\r
-// Is the script installed?\r
-if (defined('mxchange_installed') && (mxchange_installed))\r
-{\r
-       // Check for userid\r
-       if (!empty($_GET['uid']))\r
-       {\r
-               $uid = 0;\r
-               if (bigintval($_GET['uid']) != $_GET['uid'])\r
-               {\r
-                       if (EXT_IS_ACTIVE("nickname"))\r
-                       {\r
-                               // Maybe we have found a nickname?\r
-                               $result = SQL_QUERY_ESC("SELECT userid, beg_clicks, ref_payout, status, last_online FROM "._MYSQL_PREFIX."_user_data WHERE nickname='%s' LIMIT 1",\r
-                                array($_GET['uid']), __FILE__, __LINE__);\r
-                       }\r
-                        else\r
-                       {\r
-                               // Nickname entered but nickname is not active\r
-                               $msg = CODE_EXTENSION_PROBLEM;\r
-                               $uid = -1;\r
-                               $result = false;\r
-                       }\r
-               }\r
-                else\r
-               {\r
-                       // Direct userid\r
-                       $result = SQL_QUERY_ESC("SELECT userid, beg_clicks, ref_payout, status, last_online FROM "._MYSQL_PREFIX."_user_data WHERE userid=%d LIMIT 1",\r
-                        array(bigintval($_GET['uid'])), __FILE__, __LINE__);\r
-               }\r
-\r
-               // Check if locked in so don't pay points\r
-               $login = false; $status = "failed";\r
-               if (IS_LOGGED_IN())\r
-               {\r
-                       // Logged in user detected!\r
-                       $login = true;\r
-               }\r
-\r
-               // Check if account was found\r
-               if ((SQL_NUMROWS($result) == 1) && ($result != false))\r
-               {\r
-                       // Found an ID so we simply set it\r
-                       list($uid, $clicks, $ref_payout, $status, $last) = SQL_FETCHROW($result);\r
-                       if ($status == "CONFIRMED")\r
-                       {\r
-                               // Secure userid\r
-                               $uid = bigintval($uid);\r
-\r
-                               // Calculate beg points\r
-                               srand((double)microtime() * 10000000000 / time());\r
-\r
-                               // Multiply configured values with 100000 and divide with 100000 so we can also handle small values\r
-                               // If we need more number behind the decimal dot then we just need to increase all these three\r
-                               // numbers matching to the numbers behind the decimal dot. Simple! ;-)\r
-                               $POINTS = rand(($CONFIG['beg_points'] * 100000), ($CONFIG['beg_points_max'] * 100000)) / 100000;\r
-\r
-                               // Set nickname / userid for the template(s\r
-                               define('__BEG_UID'   , $_GET['uid']);\r
-                               define('__BEG_CLICKS', ($clicks + 1));\r
-                               define('__BEG_BANNER', LOAD_TEMPLATE("beg_banner", true));\r
-                               define('__BEG_POINTS', TRANSLATE_COMMA($POINTS));\r
-                       }\r
-                        else\r
-                       {\r
-                               // Other status\r
-                               $uid = "0";\r
-                       }\r
-               }\r
-\r
-               // Free memory\r
-               SQL_FREERESULT($result);\r
-\r
-               if (($uid > 0) && ($CONFIG['beg_uid'] != $uid))\r
-               {\r
-                       // Update counter\r
-                       $result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_user_data SET beg_clicks=beg_clicks+1 WHERE userid=%d AND status='CONFIRMED' LIMIT 1",\r
-                        array($uid), __FILE__, __LINE__);\r
-\r
-                       // Check for last entry for userid w/o IP number\r
-                       $result = SQL_QUERY_ESC("SELECT id FROM "._MYSQL_PREFIX."_beg_ips WHERE (timeout > ".(time() - $CONFIG['beg_timeout'])." OR (timeout > ".(time() - $CONFIG['beg_uid_timeout'])." AND userid=%d)) AND remote_ip='%s' LIMIT 1",\r
-                        array($uid, getenv('REMOTE_ADDR')), __FILE__, __LINE__);\r
-                       if ((SQL_NUMROWS($result) == 0) && ($POINTS > 0) && (!$login))\r
-                       {\r
-                               // Free memory\r
-                               SQL_FREERESULT($result);\r
-\r
-                               if (!IS_ADMIN())\r
-                               {\r
-                                       // Remember remote address, userid and timestamp for next click\r
-                                       // but only when there is no admin begging.\r
-                                       // Admins shall be able to test it!\r
-                                       $result = SQL_QUERY_ESC("INSERT INTO "._MYSQL_PREFIX."_beg_ips (userid, remote_ip, timeout) VALUES('%s', '%s', UNIX_TIMESTAMP())",\r
-                                        array($uid, getenv('REMOTE_ADDR')), __FILE__, __LINE__);\r
-                               }\r
-\r
-                               // Set mode depending on how many mails the member has to confirm\r
-                               $locked = false;\r
-                               if (($ref_payout > 0) && ($CONFIG['allow_direct_pay'] == "N")) $locked = true;\r
-\r
-                               // Is begging rallye active?\r
-                               if ($CONFIG['beg_rallye'] == "Y")\r
-                               {\r
-                                       // Add points to rallye account\r
-                                       $result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_user_data SET beg_points=beg_points+%s WHERE userid=%d LIMIT 1",\r
-                                        array($POINTS, $uid), __FILE__, __LINE__);\r
-                               }\r
-                                else\r
-                               {\r
-                                       // Add points to account\r
-                                       ADD_POINTS_REFSYSTEM($uid, $POINTS, false, "0", $locked, strtolower($CONFIG['beg_mode']));\r
-                               }\r
-\r
-                               // Subtract begged points from member account if the admin has selected one\r
-                               if ($CONFIG['beg_uid'] > 0)\r
-                               {\r
-                                       // Subtract from this account\r
-                                       $result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_user_data SET used_points=used_points+%s WHERE userid=%d LIMIT 1",\r
-                                        array($POINTS, bigintval($CONFIG['beg_uid'])), __FILE__, __LINE__);\r
-\r
-                                       // Update mediadata as well\r
-                                       if (GET_EXT_VERSION("mediadata") >= "0.0.4")\r
-                                       {\r
-                                               // Update database\r
-                                               MEDIA_UPDATE_ENTRY(array("total_points"), "sub", $POINTS);\r
-                                       }\r
-                               }\r
-\r
-                               // Set message\r
-                               define('__BEG_MSG', LOAD_TEMPLATE("beg_done", true));\r
-                       }\r
-                        elseif ($login)\r
-                       {\r
-                               // Logged in user found!\r
-                               define('__BEG_MSG', LOAD_TEMPLATE("beg_login", true));\r
-\r
-                               // Free memory\r
-                               SQL_FREERESULT($result);\r
-                       }\r
-                        else\r
-                       {\r
-                               // Free memory\r
-                               SQL_FREERESULT($result);\r
-\r
-                               // Clicked received while reload lock is active\r
-                               define('__BEG_MSG', LOAD_TEMPLATE("beg_failed", true));\r
-                       }\r
-\r
-                       // Include header\r
-                       require_once(PATH."inc/header.php");\r
-\r
-                       // Load final template\r
-                       LOAD_TEMPLATE("beg_link");\r
-\r
-                       // Include footer\r
-                       require_once(PATH."inc/footer.php");\r
-               }\r
-                elseif (($status != "CONFIRMED") && ($status != "failed"))\r
-               {\r
-                       // Maybe locked/unconfirmed account?\r
-                       switch ($status)\r
-                       {\r
-                               case "LOCKED"     : $msg = CODE_ID_LOCKED     ; break; // Locked account\r
-                               case "UNCONFIRMED": $msg = CODE_ID_UNCONFIRMED; break; // Unconfirmed account\r
-                       }\r
-               }\r
-                elseif (($uid == "0") || ($status == "failed"))\r
-               {\r
-                       // Inalid or locked account, so let's find out\r
-                       $result = SQL_QUERY_ESC("SELECT userid FROM "._MYSQL_PREFIX."_user_data WHERE nickname='%s' LIMIT 1",\r
-                        array($_GET['uid']), __FILE__, __LINE__);\r
-                       if (SQL_NUMROWS($result) == 1)\r
-                       {\r
-                               // Locked account\r
-                               $msg = CODE_ACCOUNT_LOCKED;\r
-                       }\r
-                        else\r
-                       {\r
-                               // Invalid nickname! (404)\r
-                               $msg = CODE_USER_404;\r
-                       }\r
-\r
-                       // Free memory\r
-                       SQL_FREERESULT($result);\r
-               }\r
-                elseif ($uid = $CONFIG['beg_uid'])\r
-               {\r
-                       // Webmaster's ID cannot beg for points!\r
-                       $msg = CODE_BEG_SAME_AS_OWN;\r
-               }\r
-\r
-               // Reload to index module\r
-               if ((!empty($msg)) && (!empty($msg))) LOAD_URL(URL."/modules.php?module=index&msg=".$msg);\r
-       }\r
-        else\r
-       {\r
-               // No userid entered\r
-               LOAD_URL(URL."/modules.php?module=index");\r
-       }\r
-}\r
- else\r
-{\r
-       // You have to configure first!\r
-       LOAD_URL(URL."/install.php");\r
-}\r
-// Really all done here... ;-)\r
-?>\r
+<?php
+/************************************************************************
+ * MXChange v0.2.1                                    Start: 01/09/2005 *
+ * ===============                              Last change: 01/09/2005 *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * File              : beg.php                                          *
+ * -------------------------------------------------------------------- *
+ * Short description : Beg link for members                             *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung  : Bettel-Link fuer Mitglieder                      *
+ * -------------------------------------------------------------------- *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2008 by Roland Haeder                           *
+ * For more information visit: http://www.mxchange.org                  *
+ *                                                                      *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or    *
+ * (at your option) any later version.                                  *
+ *                                                                      *
+ * This program is distributed in the hope that it will be useful,      *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of       *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *
+ * GNU General Public License for more details.                         *
+ *                                                                      *
+ * You should have received a copy of the GNU General Public License    *
+ * along with this program; if not, write to the Free Software          *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
+ * MA  02110-1301  USA                                                  *
+ ************************************************************************/
+
+// Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
+require_once("inc/libs/security_functions.php");
+
+// Init "action" and "what"
+global $what, $action;
+$GLOBALS['what'] = ""; $GLOBALS['action'] = "";
+if (!empty($_GET['action'])) $GLOBALS['action'] = secureString($_GET['action']);
+if (!empty($_GET['what'])) $GLOBALS['what'] = secureString($_GET['what']);
+
+// Set module
+$GLOBALS['module'] = "beg";
+$GLOBALS['refid']  = 0;
+$CSS = -1;
+
+// Load the required file(s)
+require ("inc/config.php");
+
+// Is the script installed?
+if (defined('mxchange_installed') && (mxchange_installed))
+{
+       // Check for userid
+       if (!empty($_GET['uid']))
+       {
+               $uid = 0;
+               if (bigintval($_GET['uid']) != $_GET['uid'])
+               {
+                       if (EXT_IS_ACTIVE("nickname"))
+                       {
+                               // Maybe we have found a nickname?
+                               $result = SQL_QUERY_ESC("SELECT userid, beg_clicks, ref_payout, status, last_online FROM "._MYSQL_PREFIX."_user_data WHERE nickname='%s' LIMIT 1",
+                                array($_GET['uid']), __FILE__, __LINE__);
+                       }
+                        else
+                       {
+                               // Nickname entered but nickname is not active
+                               $msg = CODE_EXTENSION_PROBLEM;
+                               $uid = -1;
+                               $result = false;
+                       }
+               }
+                else
+               {
+                       // Direct userid
+                       $result = SQL_QUERY_ESC("SELECT userid, beg_clicks, ref_payout, status, last_online FROM "._MYSQL_PREFIX."_user_data WHERE userid=%d LIMIT 1",
+                        array(bigintval($_GET['uid'])), __FILE__, __LINE__);
+               }
+
+               // Check if locked in so don't pay points
+               $login = false; $status = "failed";
+               if (IS_LOGGED_IN())
+               {
+                       // Logged in user detected!
+                       $login = true;
+               }
+
+               // Check if account was found
+               if ((SQL_NUMROWS($result) == 1) && ($result != false))
+               {
+                       // Found an ID so we simply set it
+                       list($uid, $clicks, $ref_payout, $status, $last) = SQL_FETCHROW($result);
+                       if ($status == "CONFIRMED")
+                       {
+                               // Secure userid
+                               $uid = bigintval($uid);
+
+                               // Calculate beg points
+                               srand((double)microtime() * 10000000000 / time());
+
+                               // Multiply configured values with 100000 and divide with 100000 so we can also handle small values
+                               // If we need more number behind the decimal dot then we just need to increase all these three
+                               // numbers matching to the numbers behind the decimal dot. Simple! ;-)
+                               $POINTS = rand(($CONFIG['beg_points'] * 100000), ($CONFIG['beg_points_max'] * 100000)) / 100000;
+
+                               // Set nickname / userid for the template(s
+                               define('__BEG_UID'   , $_GET['uid']);
+                               define('__BEG_CLICKS', ($clicks + 1));
+                               define('__BEG_BANNER', LOAD_TEMPLATE("beg_banner", true));
+                               define('__BEG_POINTS', TRANSLATE_COMMA($POINTS));
+                       }
+                        else
+                       {
+                               // Other status
+                               $uid = "0";
+                       }
+               }
+
+               // Free memory
+               SQL_FREERESULT($result);
+
+               if (($uid > 0) && ($CONFIG['beg_uid'] != $uid))
+               {
+                       // Update counter
+                       $result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_user_data SET beg_clicks=beg_clicks+1 WHERE userid=%d AND status='CONFIRMED' LIMIT 1",
+                        array($uid), __FILE__, __LINE__);
+
+                       // Check for last entry for userid w/o IP number
+                       $result = SQL_QUERY_ESC("SELECT id FROM "._MYSQL_PREFIX."_beg_ips WHERE (timeout > ".(time() - $CONFIG['beg_timeout'])." OR (timeout > ".(time() - $CONFIG['beg_uid_timeout'])." AND userid=%d)) AND remote_ip='%s' LIMIT 1",
+                        array($uid, getenv('REMOTE_ADDR')), __FILE__, __LINE__);
+                       if ((SQL_NUMROWS($result) == 0) && ($POINTS > 0) && (!$login))
+                       {
+                               // Free memory
+                               SQL_FREERESULT($result);
+
+                               if (!IS_ADMIN())
+                               {
+                                       // Remember remote address, userid and timestamp for next click
+                                       // but only when there is no admin begging.
+                                       // Admins shall be able to test it!
+                                       $result = SQL_QUERY_ESC("INSERT INTO "._MYSQL_PREFIX."_beg_ips (userid, remote_ip, timeout) VALUES('%s', '%s', UNIX_TIMESTAMP())",
+                                        array($uid, getenv('REMOTE_ADDR')), __FILE__, __LINE__);
+                               }
+
+                               // Set mode depending on how many mails the member has to confirm
+                               $locked = false;
+                               if (($ref_payout > 0) && ($CONFIG['allow_direct_pay'] == "N")) $locked = true;
+
+                               // Is begging rallye active?
+                               if ($CONFIG['beg_rallye'] == "Y")
+                               {
+                                       // Add points to rallye account
+                                       $result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_user_data SET beg_points=beg_points+%s WHERE userid=%d LIMIT 1",
+                                        array($POINTS, $uid), __FILE__, __LINE__);
+                               }
+                                else
+                               {
+                                       // Add points to account
+                                       ADD_POINTS_REFSYSTEM($uid, $POINTS, false, "0", $locked, strtolower($CONFIG['beg_mode']));
+                               }
+
+                               // Subtract begged points from member account if the admin has selected one
+                               if ($CONFIG['beg_uid'] > 0)
+                               {
+                                       // Subtract from this account
+                                       $result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_user_data SET used_points=used_points+%s WHERE userid=%d LIMIT 1",
+                                        array($POINTS, bigintval($CONFIG['beg_uid'])), __FILE__, __LINE__);
+
+                                       // Update mediadata as well
+                                       if (GET_EXT_VERSION("mediadata") >= "0.0.4")
+                                       {
+                                               // Update database
+                                               MEDIA_UPDATE_ENTRY(array("total_points"), "sub", $POINTS);
+                                       }
+                               }
+
+                               // Set message
+                               define('__BEG_MSG', LOAD_TEMPLATE("beg_done", true));
+                       }
+                        elseif ($login)
+                       {
+                               // Logged in user found!
+                               define('__BEG_MSG', LOAD_TEMPLATE("beg_login", true));
+
+                               // Free memory
+                               SQL_FREERESULT($result);
+                       }
+                        else
+                       {
+                               // Free memory
+                               SQL_FREERESULT($result);
+
+                               // Clicked received while reload lock is active
+                               define('__BEG_MSG', LOAD_TEMPLATE("beg_failed", true));
+                       }
+
+                       // Include header
+                       require_once(PATH."inc/header.php");
+
+                       // Load final template
+                       LOAD_TEMPLATE("beg_link");
+
+                       // Include footer
+                       require_once(PATH."inc/footer.php");
+               }
+                elseif (($status != "CONFIRMED") && ($status != "failed"))
+               {
+                       // Maybe locked/unconfirmed account?
+                       switch ($status)
+                       {
+                               case "LOCKED"     : $msg = CODE_ID_LOCKED     ; break; // Locked account
+                               case "UNCONFIRMED": $msg = CODE_ID_UNCONFIRMED; break; // Unconfirmed account
+                       }
+               }
+                elseif (($uid == "0") || ($status == "failed"))
+               {
+                       // Inalid or locked account, so let's find out
+                       $result = SQL_QUERY_ESC("SELECT userid FROM "._MYSQL_PREFIX."_user_data WHERE nickname='%s' LIMIT 1",
+                        array($_GET['uid']), __FILE__, __LINE__);
+                       if (SQL_NUMROWS($result) == 1)
+                       {
+                               // Locked account
+                               $msg = CODE_ACCOUNT_LOCKED;
+                       }
+                        else
+                       {
+                               // Invalid nickname! (404)
+                               $msg = CODE_USER_404;
+                       }
+
+                       // Free memory
+                       SQL_FREERESULT($result);
+               }
+                elseif ($uid = $CONFIG['beg_uid'])
+               {
+                       // Webmaster's ID cannot beg for points!
+                       $msg = CODE_BEG_SAME_AS_OWN;
+               }
+
+               // Reload to index module
+               if ((!empty($msg)) && (!empty($msg))) LOAD_URL(URL."/modules.php?module=index&msg=".$msg);
+       }
+        else
+       {
+               // No userid entered
+               LOAD_URL(URL."/modules.php?module=index");
+       }
+}
+ else
+{
+       // You have to configure first!
+       LOAD_URL(URL."/install.php");
+}
+// Really all done here... ;-)
+?>
index 8b6b78948ee48fff1bb610e9e3eadc918f1c8dfa..abc3bad31f492c87949df28684d8672adeac3d6c 100644 (file)
-<?php\r
-/************************************************************************\r
- * MXChange v0.2.1                                    Start: 10/03/2004 *\r
- * ===============                              Last change: 10/03/2004 *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * File              : birthday_confirm.php                             *\r
- * -------------------------------------------------------------------- *\r
- * Short description : Birthday bonus confirmation link                 *\r
- * -------------------------------------------------------------------- *\r
- * Kurzbeschreibung  : Geburtstagsgutschrift bestaetigen                *\r
- * -------------------------------------------------------------------- *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * Copyright (c) 2003 - 2008 by Roland Haeder                           *\r
- * For more information visit: http://www.mxchange.org                  *\r
- *                                                                      *\r
- * This program is free software; you can redistribute it and/or modify *\r
- * it under the terms of the GNU General Public License as published by *\r
- * the Free Software Foundation; either version 2 of the License, or    *\r
- * (at your option) any later version.                                  *\r
- *                                                                      *\r
- * This program is distributed in the hope that it will be useful,      *\r
- * but WITHOUT ANY WARRANTY; without even the implied warranty of       *\r
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *\r
- * GNU General Public License for more details.                         *\r
- *                                                                      *\r
- * You should have received a copy of the GNU General Public License    *\r
- * along with this program; if not, write to the Free Software          *\r
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *\r
- * MA  02110-1301  USA                                                  *\r
- ************************************************************************/\r
-\r
-// Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )\r
-require_once("inc/libs/security_functions.php");\r
-\r
-// Init "action" and "what"\r
-global $what, $action;\r
-$GLOBALS['what'] = ""; $GLOBALS['action'] = "";\r
-if (!empty($_GET['action'])) $GLOBALS['action'] = secureString($_GET['action']);\r
-if (!empty($_GET['what'])) $GLOBALS['what'] = secureString($_GET['what']);\r
-\r
-// Set module\r
-$GLOBALS['module'] = "birthday_confirm"; $CSS = -1;\r
-\r
-// Load the required file(s)\r
-require ("inc/config.php");\r
-\r
-if (defined('mxchange_installed') && (mxchange_installed))\r
-{\r
-       // Script is installed so let's check for his confirmation link...\r
-       $uid = strip_tags(bigintval($_GET['uid']));\r
-\r
-       // Only allow numbers here...\r
-       $chk = strip_tags(bigintval($_GET['check']));\r
-\r
-       // .. only first 32 numbers\r
-       $chk = substr($chk, 0, 32);\r
-\r
-       // Check if link is not clicked so far\r
-       $result = SQL_QUERY_ESC("SELECT DISTINCT b.points, d.sex, d.surname, d.family, d.status\r
-FROM "._MYSQL_PREFIX."_user_birthday AS b\r
-LEFT JOIN "._MYSQL_PREFIX."_user_data AS d\r
-ON b.userid=d.userid\r
-WHERE b.userid=%d AND b.chk_value='%s' LIMIT 1",\r
- array($uid, $chk), __FILE__, __LINE__);\r
-\r
-       if (SQL_NUMROWS($result) == 1)\r
-       {\r
-               // Ok, congratulation again! Here's your gift from us...\r
-               list($GIFT, $salut, $sname, $fname, $status) = SQL_FETCHROW($result);\r
-               if ($status == "CONFIRMED")\r
-               {\r
-                       // Set mode depending on how many mails the member has to confirm\r
-                       $locked = false;\r
-                       if (($ref_payout > 0) && ($CONFIG['allow_direct_pay'] == "N")) $locked = true;\r
-\r
-                       // Add points to account\r
-                       ADD_POINTS_REFSYSTEM($uid, $GIFT, false, "0", $locked, strtolower($CONFIG['birthday_mode']));\r
-\r
-                       // Remove entry from table\r
-                       $result = SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_user_birthday WHERE userid=%d LIMIT 1",\r
-                        array($uid), __FILE__, __LINE__);\r
-\r
-                       // Update mediadata if version is 0.0.4 or newer\r
-                       if (GET_EXT_VERSION("mediadata") >= "0.0.4")\r
-                       {\r
-                               // Update database\r
-                               MEDIA_UPDATE_ENTRY(array("total_points"), "add", $GIFT);\r
-                       }\r
-\r
-                       // Transfer data to constants for the template\r
-                       define('__SALUT', TRANSLATE_SEX($salut));\r
-                       define('__SNAME', $sname);\r
-                       define('__FNAME', $fname);\r
-                       define('__GIFT' , $GIFT);\r
-\r
-                       // Load message from template\r
-                       define('__MSG', LOAD_TEMPLATE("birthday_msg", true));\r
-               }\r
-                else\r
-               {\r
-                       // Unconfirmed / locked accounts cannot get points\r
-                       define('__MSG', BIRTHDAY_CANNOT_STATUS_1.TRANSLATE_STATUS($status).BIRTHDAY_CANNOT_STATUS_2);\r
-               }\r
-       }\r
-        else\r
-       {\r
-               // Cannot load data!\r
-               define('__MSG', BIRTHDAY_CANNOT_LOAD_DATA);\r
-       }\r
-\r
-       // Free memory\r
-       SQL_FREERESULT($result);\r
-\r
-       // Set this because we have no module in URI\r
-       $GLOBALS['module'] = "birthday_confirm";\r
-\r
-       // Include header\r
-       include(PATH."inc/header.php");\r
-\r
-       // Load birthday header template (for your banners, e.g.?)\r
-       define('__BIRTHDAY_HEADER', LOAD_TEMPLATE("birthday_header", true));\r
-\r
-       // Load birthday footer template (for your banners, e.g.?)\r
-       define('__BIRTHDAY_FOOTER', LOAD_TEMPLATE("birthday_footer", true));\r
-\r
-       // Load final template and output it\r
-       LOAD_TEMPLATE("birthday_confirm");\r
-\r
-       // Include footer\r
-       include(PATH."inc/footer.php");\r
-}\r
- else\r
-{\r
-       // You have to configure first!\r
-       LOAD_URL(URL."/install.php");\r
-}\r
-// Really all done here... ;-)\r
-?>\r
+<?php
+/************************************************************************
+ * MXChange v0.2.1                                    Start: 10/03/2004 *
+ * ===============                              Last change: 10/03/2004 *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * File              : birthday_confirm.php                             *
+ * -------------------------------------------------------------------- *
+ * Short description : Birthday bonus confirmation link                 *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung  : Geburtstagsgutschrift bestaetigen                *
+ * -------------------------------------------------------------------- *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2008 by Roland Haeder                           *
+ * For more information visit: http://www.mxchange.org                  *
+ *                                                                      *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or    *
+ * (at your option) any later version.                                  *
+ *                                                                      *
+ * This program is distributed in the hope that it will be useful,      *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of       *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *
+ * GNU General Public License for more details.                         *
+ *                                                                      *
+ * You should have received a copy of the GNU General Public License    *
+ * along with this program; if not, write to the Free Software          *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
+ * MA  02110-1301  USA                                                  *
+ ************************************************************************/
+
+// Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
+require_once("inc/libs/security_functions.php");
+
+// Init "action" and "what"
+global $what, $action;
+$GLOBALS['what'] = ""; $GLOBALS['action'] = "";
+if (!empty($_GET['action'])) $GLOBALS['action'] = secureString($_GET['action']);
+if (!empty($_GET['what'])) $GLOBALS['what'] = secureString($_GET['what']);
+
+// Set module
+$GLOBALS['module'] = "birthday_confirm"; $CSS = -1;
+
+// Load the required file(s)
+require ("inc/config.php");
+
+if (defined('mxchange_installed') && (mxchange_installed))
+{
+       // Script is installed so let's check for his confirmation link...
+       $uid = strip_tags(bigintval($_GET['uid']));
+
+       // Only allow numbers here...
+       $chk = strip_tags(bigintval($_GET['check']));
+
+       // .. only first 32 numbers
+       $chk = substr($chk, 0, 32);
+
+       // Check if link is not clicked so far
+       $result = SQL_QUERY_ESC("SELECT DISTINCT b.points, d.sex, d.surname, d.family, d.status
+FROM "._MYSQL_PREFIX."_user_birthday AS b
+LEFT JOIN "._MYSQL_PREFIX."_user_data AS d
+ON b.userid=d.userid
+WHERE b.userid=%d AND b.chk_value='%s' LIMIT 1",
+ array($uid, $chk), __FILE__, __LINE__);
+
+       if (SQL_NUMROWS($result) == 1)
+       {
+               // Ok, congratulation again! Here's your gift from us...
+               list($GIFT, $salut, $sname, $fname, $status) = SQL_FETCHROW($result);
+               if ($status == "CONFIRMED")
+               {
+                       // Set mode depending on how many mails the member has to confirm
+                       $locked = false;
+                       if (($ref_payout > 0) && ($CONFIG['allow_direct_pay'] == "N")) $locked = true;
+
+                       // Add points to account
+                       ADD_POINTS_REFSYSTEM($uid, $GIFT, false, "0", $locked, strtolower($CONFIG['birthday_mode']));
+
+                       // Remove entry from table
+                       $result = SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_user_birthday WHERE userid=%d LIMIT 1",
+                        array($uid), __FILE__, __LINE__);
+
+                       // Update mediadata if version is 0.0.4 or newer
+                       if (GET_EXT_VERSION("mediadata") >= "0.0.4")
+                       {
+                               // Update database
+                               MEDIA_UPDATE_ENTRY(array("total_points"), "add", $GIFT);
+                       }
+
+                       // Transfer data to constants for the template
+                       define('__SALUT', TRANSLATE_SEX($salut));
+                       define('__SNAME', $sname);
+                       define('__FNAME', $fname);
+                       define('__GIFT' , $GIFT);
+
+                       // Load message from template
+                       define('__MSG', LOAD_TEMPLATE("birthday_msg", true));
+               }
+                else
+               {
+                       // Unconfirmed / locked accounts cannot get points
+                       define('__MSG', BIRTHDAY_CANNOT_STATUS_1.TRANSLATE_STATUS($status).BIRTHDAY_CANNOT_STATUS_2);
+               }
+       }
+        else
+       {
+               // Cannot load data!
+               define('__MSG', BIRTHDAY_CANNOT_LOAD_DATA);
+       }
+
+       // Free memory
+       SQL_FREERESULT($result);
+
+       // Set this because we have no module in URI
+       $GLOBALS['module'] = "birthday_confirm";
+
+       // Include header
+       include(PATH."inc/header.php");
+
+       // Load birthday header template (for your banners, e.g.?)
+       define('__BIRTHDAY_HEADER', LOAD_TEMPLATE("birthday_header", true));
+
+       // Load birthday footer template (for your banners, e.g.?)
+       define('__BIRTHDAY_FOOTER', LOAD_TEMPLATE("birthday_footer", true));
+
+       // Load final template and output it
+       LOAD_TEMPLATE("birthday_confirm");
+
+       // Include footer
+       include(PATH."inc/footer.php");
+}
+ else
+{
+       // You have to configure first!
+       LOAD_URL(URL."/install.php");
+}
+// Really all done here... ;-)
+?>
index 84868a67934233fa9d643fc4cc4ac6cc78a1ba85..9ad11a125ec16613026ab4928b0c899f733e4f15 100644 (file)
@@ -1,73 +1,73 @@
-<?php\r
-/************************************************************************\r
- * MXChange v0.2.1                                    Start: 01/02/2004 *\r
- * ===============                              Last change: 06/18/2004 *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * File              : click.php                                        *\r
- * -------------------------------------------------------------------- *\r
- * Short description : Count clicks on a banner and redirect...         *\r
- * -------------------------------------------------------------------- *\r
- * Kurzbeschreibung  : Klicks auf Banner zaehlen und weiterleiten       *\r
- * -------------------------------------------------------------------- *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * Copyright (c) 2003 - 2008 by Roland Haeder                           *\r
- * For more information visit: http://www.mxchange.org                  *\r
- *                                                                      *\r
- * This program is free software; you can redistribute it and/or modify *\r
- * it under the terms of the GNU General Public License as published by *\r
- * the Free Software Foundation; either version 2 of the License, or    *\r
- * (at your option) any later version.                                  *\r
- *                                                                      *\r
- * This program is distributed in the hope that it will be useful,      *\r
- * but WITHOUT ANY WARRANTY; without even the implied warranty of       *\r
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *\r
- * GNU General Public License for more details.                         *\r
- *                                                                      *\r
- * You should have received a copy of the GNU General Public License    *\r
- * along with this program; if not, write to the Free Software          *\r
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *\r
- * MA  02110-1301  USA                                                  *\r
- ************************************************************************/\r
-\r
-// Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )\r
-require_once("inc/libs/security_functions.php");\r
-\r
-// Init "action" and "what"\r
-global $what, $action;\r
-$GLOBALS['what'] = ""; $GLOBALS['action'] = "";\r
-if (!empty($_GET['action'])) $GLOBALS['action'] = secureString($_GET['action']);\r
-if (!empty($_GET['what'])) $GLOBALS['what'] = secureString($_GET['what']);\r
-\r
-// Set module\r
-$GLOBALS['module'] = "click"; $CSS = -1;\r
-\r
-// Load the required file(s)\r
-require ("inc/config.php");\r
-\r
-if (((!empty($_GET['user'])) || (!empty($_GET['reseller']))) && (!empty($_GET['banner'])))\r
-{\r
-       // Update clicks counter...\r
-       $CLICK = 1;\r
-       $result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_refbanner SET clicks=clicks+1 WHERE id=%d LIMIT 1", array(bigintval($_GET['banner'])), __FILE__, __LINE__);\r
-       if (SQL_AFFECTEDROWS($link) == 1)\r
-       {\r
-               if (!empty($_GET['user']))\r
-               {\r
-                       LOAD_URL("ref.php?refid=".$_GET['user']);\r
-               }\r
-                else\r
-               {\r
-                       LOAD_URL("shop_reseller.php?reseller=".$_GET['reseller']);\r
-               }\r
-       }\r
-       exit();\r
-}\r
- else\r
-{\r
-       // Do nothing for now\r
-       die();\r
-}\r
-//\r
-?>\r
+<?php
+/************************************************************************
+ * MXChange v0.2.1                                    Start: 01/02/2004 *
+ * ===============                              Last change: 06/18/2004 *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * File              : click.php                                        *
+ * -------------------------------------------------------------------- *
+ * Short description : Count clicks on a banner and redirect...         *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung  : Klicks auf Banner zaehlen und weiterleiten       *
+ * -------------------------------------------------------------------- *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2008 by Roland Haeder                           *
+ * For more information visit: http://www.mxchange.org                  *
+ *                                                                      *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or    *
+ * (at your option) any later version.                                  *
+ *                                                                      *
+ * This program is distributed in the hope that it will be useful,      *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of       *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *
+ * GNU General Public License for more details.                         *
+ *                                                                      *
+ * You should have received a copy of the GNU General Public License    *
+ * along with this program; if not, write to the Free Software          *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
+ * MA  02110-1301  USA                                                  *
+ ************************************************************************/
+
+// Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
+require_once("inc/libs/security_functions.php");
+
+// Init "action" and "what"
+global $what, $action;
+$GLOBALS['what'] = ""; $GLOBALS['action'] = "";
+if (!empty($_GET['action'])) $GLOBALS['action'] = secureString($_GET['action']);
+if (!empty($_GET['what'])) $GLOBALS['what'] = secureString($_GET['what']);
+
+// Set module
+$GLOBALS['module'] = "click"; $CSS = -1;
+
+// Load the required file(s)
+require ("inc/config.php");
+
+if (((!empty($_GET['user'])) || (!empty($_GET['reseller']))) && (!empty($_GET['banner'])))
+{
+       // Update clicks counter...
+       $CLICK = 1;
+       $result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_refbanner SET clicks=clicks+1 WHERE id=%d LIMIT 1", array(bigintval($_GET['banner'])), __FILE__, __LINE__);
+       if (SQL_AFFECTEDROWS($link) == 1)
+       {
+               if (!empty($_GET['user']))
+               {
+                       LOAD_URL("ref.php?refid=".$_GET['user']);
+               }
+                else
+               {
+                       LOAD_URL("shop_reseller.php?reseller=".$_GET['reseller']);
+               }
+       }
+       exit();
+}
+ else
+{
+       // Do nothing for now
+       die();
+}
+//
+?>
index 9d18c113946447246f302324f746668583169ca0..606a41715f19a6680e8173ab61d9c10e0d37013f 100644 (file)
@@ -1,74 +1,74 @@
-<?php\r
-/************************************************************************\r
- * MXChange v0.2.1                                    Start: 10/13/2003 *\r
- * ===============                              Last change: 04/26/2004 *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * File              : confirm.php                                      *\r
- * -------------------------------------------------------------------- *\r
- * Short description : Redirection for the confirmation link            *\r
- * -------------------------------------------------------------------- *\r
- * Kurzbeschreibung  : Weiterleitungsscript f�r den Best�tigungslink    *\r
- * -------------------------------------------------------------------- *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * Copyright (c) 2003 - 2008 by Roland Haeder                           *\r
- * For more information visit: http://www.mxchange.org                  *\r
- *                                                                      *\r
- * This program is free software; you can redistribute it and/or modify *\r
- * it under the terms of the GNU General Public License as published by *\r
- * the Free Software Foundation; either version 2 of the License, or    *\r
- * (at your option) any later version.                                  *\r
- *                                                                      *\r
- * This program is distributed in the hope that it will be useful,      *\r
- * but WITHOUT ANY WARRANTY; without even the implied warranty of       *\r
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *\r
- * GNU General Public License for more details.                         *\r
- *                                                                      *\r
- * You should have received a copy of the GNU General Public License    *\r
- * along with this program; if not, write to the Free Software          *\r
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *\r
- * MA  02110-1301  USA                                                  *\r
- ************************************************************************/\r
-\r
-// Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )\r
-require_once("inc/libs/security_functions.php");\r
-\r
-// Init "action" and "what"\r
-global $what, $action;\r
-$GLOBALS['what'] = ""; $GLOBALS['action'] = "";\r
-if (!empty($_GET['action'])) $GLOBALS['action'] = secureString($_GET['action']);\r
-if (!empty($_GET['what'])) $GLOBALS['what'] = secureString($_GET['what']);\r
-\r
-// Set module to confirm\r
-$GLOBALS['module'] = "confirm"; $CSS = -1;\r
-\r
-// Load the required file(s)\r
-require ("inc/config.php");\r
-\r
-// Is the script installed?\r
-if (defined('mxchange_installed') && (mxchange_installed) && (admin_registered))\r
-{\r
-       // Base URL for redirection\r
-       $URL = URL."/modules.php?module=index&what=confirm&hash=";\r
-       if (empty($_GET['hash']))\r
-       {\r
-               // No refid and we add our refid (don't forget to set $def_refid!)\r
-               $URL = URL."/modules.php?module=index";\r
-       }\r
-        else\r
-       {\r
-               // We have an refid here. So we simply add it\r
-               $URL .= $_GET['hash'];\r
-       }\r
-       // Load the URL\r
-       LOAD_URL($URL);\r
-       // Redirection should be done here\r
-}\r
- else\r
-{\r
-       // You have to configure first!\r
-       LOAD_URL(URL."/install.php");\r
-}\r
-// Really all done here... ;-)\r
-?>\r
+<?php
+/************************************************************************
+ * MXChange v0.2.1                                    Start: 10/13/2003 *
+ * ===============                              Last change: 04/26/2004 *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * File              : confirm.php                                      *
+ * -------------------------------------------------------------------- *
+ * Short description : Redirection for the confirmation link            *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung  : Weiterleitungsscript f�r den Best�tigungslink    *
+ * -------------------------------------------------------------------- *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2008 by Roland Haeder                           *
+ * For more information visit: http://www.mxchange.org                  *
+ *                                                                      *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or    *
+ * (at your option) any later version.                                  *
+ *                                                                      *
+ * This program is distributed in the hope that it will be useful,      *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of       *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *
+ * GNU General Public License for more details.                         *
+ *                                                                      *
+ * You should have received a copy of the GNU General Public License    *
+ * along with this program; if not, write to the Free Software          *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
+ * MA  02110-1301  USA                                                  *
+ ************************************************************************/
+
+// Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
+require_once("inc/libs/security_functions.php");
+
+// Init "action" and "what"
+global $what, $action;
+$GLOBALS['what'] = ""; $GLOBALS['action'] = "";
+if (!empty($_GET['action'])) $GLOBALS['action'] = secureString($_GET['action']);
+if (!empty($_GET['what'])) $GLOBALS['what'] = secureString($_GET['what']);
+
+// Set module to confirm
+$GLOBALS['module'] = "confirm"; $CSS = -1;
+
+// Load the required file(s)
+require ("inc/config.php");
+
+// Is the script installed?
+if (defined('mxchange_installed') && (mxchange_installed) && (admin_registered))
+{
+       // Base URL for redirection
+       $URL = URL."/modules.php?module=index&what=confirm&hash=";
+       if (empty($_GET['hash']))
+       {
+               // No refid and we add our refid (don't forget to set $def_refid!)
+               $URL = URL."/modules.php?module=index";
+       }
+        else
+       {
+               // We have an refid here. So we simply add it
+               $URL .= $_GET['hash'];
+       }
+       // Load the URL
+       LOAD_URL($URL);
+       // Redirection should be done here
+}
+ else
+{
+       // You have to configure first!
+       LOAD_URL(URL."/install.php");
+}
+// Really all done here... ;-)
+?>
index e8813c42321527f6e5d9f6c246fc92546aea2252..cdc3461e4fd719079005868909cbd8593ce76193 100644 (file)
@@ -1,65 +1,65 @@
-<?php\r
-/************************************************************************\r
- * MXChange v0.2.1                                    Start: 11/06/2004 *\r
- * ===============                              Last change: 12/03/2004 *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * File              : css.php                                          *\r
- * -------------------------------------------------------------------- *\r
- * Short description : Image code for multi-purposes                    *\r
- * -------------------------------------------------------------------- *\r
- * Kurzbeschreibung  : Code-Bild fuer verschiedene Zwecke               *\r
- * -------------------------------------------------------------------- *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * Copyright (c) 2003 - 2008 by Roland Haeder                           *\r
- * For more information visit: http://www.mxchange.org                  *\r
- *                                                                      *\r
- * This program is free software; you can redistribute it and/or modify *\r
- * it under the terms of the GNU General Public License as published by *\r
- * the Free Software Foundation; either version 2 of the License, or    *\r
- * (at your option) any later version.                                  *\r
- *                                                                      *\r
- * This program is distributed in the hope that it will be useful,      *\r
- * but WITHOUT ANY WARRANTY; without even the implied warranty of       *\r
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *\r
- * GNU General Public License for more details.                         *\r
- *                                                                      *\r
- * You should have received a copy of the GNU General Public License    *\r
- * along with this program; if not, write to the Free Software          *\r
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *\r
- * MA  02110-1301  USA                                                  *\r
- ************************************************************************/\r
-\r
-// Deactivate caching system in CSS mode\r
-define('_OB_CACHING', "old");\r
-\r
-// Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )\r
-require_once("inc/libs/security_functions.php");\r
-\r
-// Init "action" and "what"\r
-global $what, $action;\r
-$GLOBALS['what'] = ""; $GLOBALS['action'] = "";\r
-if (!empty($_GET['action'])) $GLOBALS['action'] = secureString($_GET['action']);\r
-if (!empty($_GET['what'])) $GLOBALS['what'] = secureString($_GET['what']);\r
-\r
-// This is a CSS file loader!\r
-$CSS = "1"; $GLOBALS['module'] = "css";\r
-\r
-// Load the required file(s)\r
-require ("inc/config.php");\r
-\r
-// Set header\r
-@header("Content-type: text/css");\r
-\r
-// Load header\r
-require_once(PATH."inc/header.php");\r
-\r
-// Load CSS code\r
-require_once(PATH."inc/stylesheet.php");\r
-\r
-// Load footer\r
-require_once(PATH."inc/footer.php");\r
-\r
-//\r
-?>\r
+<?php
+/************************************************************************
+ * MXChange v0.2.1                                    Start: 11/06/2004 *
+ * ===============                              Last change: 12/03/2004 *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * File              : css.php                                          *
+ * -------------------------------------------------------------------- *
+ * Short description : Image code for multi-purposes                    *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung  : Code-Bild fuer verschiedene Zwecke               *
+ * -------------------------------------------------------------------- *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2008 by Roland Haeder                           *
+ * For more information visit: http://www.mxchange.org                  *
+ *                                                                      *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or    *
+ * (at your option) any later version.                                  *
+ *                                                                      *
+ * This program is distributed in the hope that it will be useful,      *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of       *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *
+ * GNU General Public License for more details.                         *
+ *                                                                      *
+ * You should have received a copy of the GNU General Public License    *
+ * along with this program; if not, write to the Free Software          *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
+ * MA  02110-1301  USA                                                  *
+ ************************************************************************/
+
+// Deactivate caching system in CSS mode
+define('_OB_CACHING', "old");
+
+// Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
+require_once("inc/libs/security_functions.php");
+
+// Init "action" and "what"
+global $what, $action;
+$GLOBALS['what'] = ""; $GLOBALS['action'] = "";
+if (!empty($_GET['action'])) $GLOBALS['action'] = secureString($_GET['action']);
+if (!empty($_GET['what'])) $GLOBALS['what'] = secureString($_GET['what']);
+
+// This is a CSS file loader!
+$CSS = "1"; $GLOBALS['module'] = "css";
+
+// Load the required file(s)
+require ("inc/config.php");
+
+// Set header
+@header("Content-type: text/css");
+
+// Load header
+require_once(PATH."inc/header.php");
+
+// Load CSS code
+require_once(PATH."inc/stylesheet.php");
+
+// Load footer
+require_once(PATH."inc/footer.php");
+
+//
+?>
index 81aefa8066b5151254cab01ab3dc8dddff3fed82..a630b2a4f484309aba4b47e28f3d1941311e1665 100644 (file)
-<?php\r
-/************************************************************************\r
- * MXChange v0.2.1                                    Start: 02/13/2005 *\r
- * ===============                              Last change: 02/13/2005 *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * File              : doubler.php                                      *\r
- * -------------------------------------------------------------------- *\r
- * Short description : Points doubler                                   *\r
- * -------------------------------------------------------------------- *\r
- * Kurzbeschreibung  : Punkteverdoppler                                 *\r
- * -------------------------------------------------------------------- *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * Copyright (c) 2003 - 2008 by Roland Haeder                           *\r
- * For more information visit: http://www.mxchange.org                  *\r
- *                                                                      *\r
- * This program is free software; you can redistribute it and/or modify *\r
- * it under the terms of the GNU General Public License as published by *\r
- * the Free Software Foundation; either version 2 of the License, or    *\r
- * (at your option) any later version.                                  *\r
- *                                                                      *\r
- * This program is distributed in the hope that it will be useful,      *\r
- * but WITHOUT ANY WARRANTY; without even the implied warranty of       *\r
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *\r
- * GNU General Public License for more details.                         *\r
- *                                                                      *\r
- * You should have received a copy of the GNU General Public License    *\r
- * along with this program; if not, write to the Free Software          *\r
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *\r
- * MA  02110-1301  USA                                                  *\r
- ************************************************************************/\r
-\r
-// Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )\r
-require_once("inc/libs/security_functions.php");\r
-\r
-// Init "action" and "what"\r
-global $what, $action;\r
-$GLOBALS['what'] = ""; $GLOBALS['action'] = "";\r
-if (!empty($_GET['action'])) $GLOBALS['action'] = secureString($_GET['action']);\r
-if (!empty($_GET['what'])) $GLOBALS['what'] = secureString($_GET['what']);\r
-\r
-// Set module\r
-$GLOBALS['module'] = "doubler";\r
-$GLOBALS['refid'] = 0;\r
-$CSS = "0";\r
-\r
-// Load the required file(s)\r
-require ("inc/config.php");\r
-\r
-// Is the script installed?\r
-if (defined('mxchange_installed') && (mxchange_installed))\r
-{\r
-       // Probe for referral ID\r
-       if (!empty($_GET['refid'])) $GLOBALS['refid'] = bigintval($_GET['refid']);\r
-\r
-       // Probe for nickname extension and if a nickname was supplied by URL\r
-       $probe_nickname = ((EXT_IS_ACTIVE("nickname")) && (("".round($GLOBALS['refid'])."") != $GLOBALS['refid']));\r
-       if ($probe_nickname)\r
-       {\r
-               // Nickname in URL, so load the ID\r
-               $result = SQL_QUERY_ESC("SELECT userid, status FROM "._MYSQL_PREFIX."_user_data WHERE nickname='%s' LIMIT 1",\r
-                array(bigintval($GLOBALS['refid'])), __FILE__, __LINE__);\r
-       }\r
-        else\r
-       {\r
-               // Direct userid entered\r
-               $result = SQL_QUERY_ESC("SELECT userid, status FROM "._MYSQL_PREFIX."_user_data WHERE userid=%d LIMIT 1",\r
-                array(bigintval($GLOBALS['refid'])), __FILE__, __LINE__);\r
-       }\r
-\r
-       // Load data\r
-       list($rid, $status_ref) = SQL_FETCHROW($result);\r
-       $GLOBALS['refid'] = bigintval($rid);\r
-\r
-       // Free memory\r
-       SQL_FREERESULT($result);\r
-       $uid = 0;\r
-\r
-       // If no account was found set default refid and status to CONFIRMED\r
-       if (empty($GLOBALS['refid'])) { $GLOBALS['refid'] = $CONFIG['def_refid']; $status = "CONFIRMED"; }\r
-\r
-       // Begin with doubler script...\r
-       if (isset($_POST['ok']))\r
-       {\r
-               // Secure points (so only integer/double values are allowed\r
-               $_POST['points'] = bigintval($_POST['points']);\r
-\r
-               // Begin with doubling process\r
-               if ((!empty($_POST['userid'])) && (!empty($_POST['pass'])) && (!empty($_POST['points'])))\r
-               {\r
-                       // Probe for nickname extension and if a nickname was entered\r
-                       $probe_nickname = ((EXT_IS_ACTIVE("nickname")) && (("".round($_POST['userid'])."") != $_POST['userid']));\r
-                       if ($probe_nickname)\r
-                       {\r
-                               // Nickname in URL, so load the ID\r
-                               $result = SQL_QUERY_ESC("SELECT userid, status, password FROM "._MYSQL_PREFIX."_user_data WHERE nickname='%s' LIMIT 1",\r
-                                array($_POST['userid']), __FILE__, __LINE__);\r
-                       }\r
-                        else\r
-                       {\r
-                               // Direct userid entered\r
-                               $result = SQL_QUERY_ESC("SELECT userid, status, password FROM "._MYSQL_PREFIX."_user_data WHERE userid=%d LIMIT 1",\r
-                                array(bigintval($_POST['userid'])), __FILE__, __LINE__);\r
-                       }\r
-\r
-                       // Load data\r
-                       list($uid, $status, $password) = SQL_FETCHROW($result);\r
-                       $uid = bigintval($uid);\r
-\r
-                       // Free result\r
-                       SQL_FREERESULT($result);\r
-\r
-                       // Remove any dots and unwanted chars from the points\r
-                       $_POST['points'] = bigintval(round(str_replace(",", ".", $_POST['points'])));\r
-\r
-                       // Probe for enough points\r
-                       $probe_points = (($_POST['points'] >= $CONFIG['doubler_min']) && ($_POST['points'] <= $CONFIG['doubler_max']));\r
-\r
-                       // Check all together\r
-                       if ((!empty($uid)) && ($password == generateHash($_POST['pass'], substr($password, 0, -40))) && ($status == "CONFIRMED") && ($probe_points))\r
-                       {\r
-                               // Nickname resolved to a unique userid or direct userid entered by the member\r
-                               $DOUBLER_UID = $uid;\r
-\r
-                               // Calulcate points\r
-                               $POINTS = GET_TOTAL_DATA($uid, "user_points", "points") - GET_TOTAL_DATA($uid, "user_data", "used_points");\r
-\r
-                               // So let's continue with probing his points amount\r
-                               if (($POINTS - $CONFIG['doubler_left'] - $_POST['points'] * $CONFIG['doubler_charge']) >= 0)\r
-                               {\r
-                                       // Enough points are left so let's continue with the doubling process\r
-                                       // Create doubling "account" width *DOUBLED* points\r
-                                       $result = SQL_QUERY_ESC("INSERT INTO "._MYSQL_PREFIX."_doubler (userid, refid, points, remote_ip, timemark, completed, is_ref) VALUES ('%s', '%s', '%s', '".$_SERVER['REMOTE_ADDR']."', UNIX_TIMESTAMP(), 'N', 'N')",\r
-                                        array($uid, bigintval($GLOBALS['refid']), bigintval($_POST['points'] * 2)), __FILE__, __LINE__);\r
-\r
-                                       // Subtract entered points\r
-                                       $result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_user_data SET used_points=used_points+%s WHERE userid=%d LIMIT 1",\r
-                                        array($_POST['points'], $uid), __FILE__, __LINE__);\r
-\r
-                                       // Update mediadata as well\r
-                                       if (GET_EXT_VERSION("mediadata") >= "0.0.4")\r
-                                       {\r
-                                               // Update database\r
-                                               MEDIA_UPDATE_ENTRY(array("total_points"), "sub", $_POST['points']);\r
-                                       }\r
-\r
-                                       // Add points to "total payed" including charge\r
-                                       $points = $_POST['points'] - $_POST['points'] * $CONFIG['doubler_charge'];\r
-                                       $result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_config SET doubler_points=doubler_points+%s WHERE config='0' LIMIT 1",\r
-                                        array($points), __FILE__, __LINE__);\r
-                                       $CONFIG['doubler_points'] += $points;\r
-\r
-                                       // Destroy cache\r
-                                       if (GET_EXT_VERSION("cache") >= "0.1.2")\r
-                                       {\r
-                                               if ($CACHE->cache_file("config", true)) $CACHE->cache_destroy();\r
-                                       }\r
-\r
-                                       // Add second line for the referral but only when uid != refid\r
-                                       if (($GLOBALS['refid'] > 0) && ($GLOBALS['refid'] != $uid))\r
-                                       {\r
-                                               // Okay add a refid line and apply refid percents\r
-                                               $result = SQL_QUERY_ESC("INSERT INTO "._MYSQL_PREFIX."_doubler (userid, refid, points, remote_ip, timemark, completed, is_ref) VALUES ('%s', '0', '%s', '".$_SERVER['REMOTE_ADDR']."', UNIX_TIMESTAMP(), 'N', 'Y')",\r
-                                                array(bigintval($GLOBALS['refid']), bigintval($_POST['points'] * 2 * $CONFIG['doubler_ref'])), __FILE__, __LINE__);\r
-\r
-                                               // And that's why we dont't want to you more than one referral level of doubler-points. ^^^\r
-                                       }\r
-\r
-                                       // Update usage counter\r
-                                       $result = SQL_QUERY("UPDATE "._MYSQL_PREFIX."_config SET doubler_counter=doubler_counter+1 WHERE config='0' LIMIT 1", __FILE__, __LINE__);\r
-                                       $CONFIG['doubler_counter']++;\r
-\r
-                                       // Set constant\r
-                                       define('__DOUBLER_MSG', LOAD_TEMPLATE("doubler_reflink", true, $_POST['userid']));\r
-                               }\r
-                                else\r
-                               {\r
-                                       // Not enougth points left\r
-                                       define('__ERROR_MSG', DOUBLER_FORM_NO_POINTS_LEFT);\r
-                               }\r
-\r
-                       }\r
-                        elseif ($status == "CONFIRMED")\r
-                       {\r
-                               // Account is unconfirmed!\r
-                               define('__ERROR_MSG', DOUBLER_FORM_WRONG_PASS);\r
-                       }\r
-                        elseif ($status == "UNCONFIRMED")\r
-                       {\r
-                               // Account is unconfirmed!\r
-                               define('__ERROR_MSG', DOUBLER_FORM_STATUS_UNCONFIRMED);\r
-                       }\r
-                        elseif ($status == "LOCKED")\r
-                       {\r
-                               // Account is locked by admin / holiday!\r
-                               define('__ERROR_MSG', DOUBLER_FORM_STATUS_LOCKED);\r
-                       }\r
-                        elseif ($_POST['points'] < $CONFIG['doubler_min'])\r
-                       {\r
-                               // Not enougth points entered\r
-                               define('__ERROR_MSG', DOUBLER_FORM_POINTS_MIN);\r
-                       }\r
-                        elseif ($_POST['points'] > $CONFIG['doubler_max'])\r
-                       {\r
-                               // Too much points entered\r
-                               define('__ERROR_MSG', DOUBLER_FORM_POINTS_MAX);\r
-                       }\r
-                        elseif ($probe_nickname)\r
-                       {\r
-                               // Cannot resolv nickname -> userid\r
-                               define('__ERROR_MSG', DOUBLER_FORM_404_NICKNAME);\r
-                       }\r
-                        else\r
-                       {\r
-                               // Wrong password or account not found\r
-                               define('__ERROR_MSG', DOUBLER_FORM_404_MEMBER);\r
-                       }\r
-               }\r
-                elseif (empty($_POST['userid']))\r
-               {\r
-                       // Login not entered\r
-                       define('__ERROR_MSG', DOUBLER_FORM_404_LOGIN);\r
-               }\r
-                elseif (empty($_POST['pass']))\r
-               {\r
-                       // Password not entered\r
-                       define('__ERROR_MSG', DOUBLER_FORM_404_PASSWORD);\r
-               }\r
-                elseif (empty($_POST['points']))\r
-               {\r
-                       // points not entered\r
-                       define('__ERROR_MSG', DOUBLER_FORM_404_POINTS);\r
-               }\r
-       }\r
-\r
-       // Set messages to nothing\r
-       if (!defined('__DOUBLER_MSG')) define('__DOUBLER_MSG', "");\r
-       if (!defined('__ERROR_MSG'))   define('__ERROR_MSG'  , "");\r
-\r
-       // Shall I check for points immediately?\r
-       if ($CONFIG['doubler_send_mode'] == "DIRECT") require(PATH."inc/doubler_send.php");\r
-\r
-       // Output header\r
-       include(PATH."inc/header.php");\r
-\r
-       // Banner in text\r
-       define('__DOUBLER_BANNER', LOAD_TEMPLATE("doubler_banner", true));\r
-\r
-       // Load header/footer templates\r
-       define('__DOUBLER_HEADER', LOAD_TEMPLATE("doubler_header", true));\r
-       define('__DOUBLER_FOOTER', LOAD_TEMPLATE("doubler_footer", true));\r
-\r
-       if (!empty($uid))\r
-       {\r
-               // Transfer userid/nickname to constant\r
-               define('__REFID', $uid);\r
-       }\r
-        elseif (!empty($GLOBALS['refid']))\r
-       {\r
-               // Transfer userid/nickname to constant\r
-               define('__REFID', $GLOBALS['refid']);\r
-       }\r
-        else\r
-       {\r
-               // Transfer default refid to constant\r
-               define('__REFID', $CONFIG['def_refid']);\r
-       }\r
-\r
-       // Percent values etc.\r
-       define('__CHARGE_VALUE', TRANSLATE_COMMA($CONFIG['doubler_charge'] * 100));\r
-       define('__REF_VALUE'   , TRANSLATE_COMMA($CONFIG['doubler_ref'] * 100));\r
-       define('__TOTAL_VALUE' , TRANSLATE_COMMA($CONFIG['doubler_points']));\r
-       define('__MIN_VALUE'   , TRANSLATE_COMMA($CONFIG['doubler_min']));\r
-       define('__MAX_VALUE'   , TRANSLATE_COMMA($CONFIG['doubler_max']));\r
-\r
-       // Text "Enter login"\r
-       if (EXT_IS_ACTIVE("nickname"))\r
-       {\r
-               // Choose login/nickname\r
-               define('DOUBLER_ENTER_LOGIN', GUEST_ENTER_LOGIN_NICKNAME);\r
-       }\r
-        else\r
-       {\r
-               // Simple login ID\r
-               define('DOUBLER_ENTER_LOGIN', GUEST_ENTER_LOGIN);\r
-       }\r
-\r
-       // Which mail-send-mode did the admin setup?\r
-       switch ($CONFIG['doubler_send_mode'])\r
-       {\r
-       case "DIRECT":\r
-               define('DOUBLER_PAYOUT_TIME', DOUBLER_PAYOUT_TIME_DIRECT);\r
-               break;\r
-\r
-       case "RESET":\r
-               define('DOUBLER_PAYOUT_TIME', DOUBLER_PAYOUT_TIME_RESET);\r
-               break;\r
-       }\r
-\r
-       // Generate table with already payed out doubles\r
-       define('__DOUBLER_PAYOUT_HISTORY', DOUBLER_GENERATE_TABLE("0", "Y", "N", "DESC"));\r
-\r
-       // Generate timemark\r
-       define('__TIMEOUT_MARK', CREATE_FANCY_TIME($CONFIG['doubler_timeout']));\r
-\r
-       // Usage counter\r
-       define('__DOUBLER_COUNTER', $CONFIG['doubler_counter']);\r
-\r
-       // Points left to doubler\r
-       define('__LEFT_VALUE', TRANSLATE_COMMA(DOUBLER_GET_TOTAL_POINTS_LEFT()));\r
-\r
-       // Output neccessary form for this\r
-       LOAD_TEMPLATE("doubler_index");\r
-\r
-       // Output footer\r
-       include(PATH."inc/footer.php");\r
-}\r
- else\r
-{\r
-       // You have to configure first!\r
-       LOAD_URL(URL."/install.php");\r
-}\r
-\r
-// Really all done here... ;-)\r
-?>\r
+<?php
+/************************************************************************
+ * MXChange v0.2.1                                    Start: 02/13/2005 *
+ * ===============                              Last change: 02/13/2005 *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * File              : doubler.php                                      *
+ * -------------------------------------------------------------------- *
+ * Short description : Points doubler                                   *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung  : Punkteverdoppler                                 *
+ * -------------------------------------------------------------------- *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2008 by Roland Haeder                           *
+ * For more information visit: http://www.mxchange.org                  *
+ *                                                                      *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or    *
+ * (at your option) any later version.                                  *
+ *                                                                      *
+ * This program is distributed in the hope that it will be useful,      *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of       *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *
+ * GNU General Public License for more details.                         *
+ *                                                                      *
+ * You should have received a copy of the GNU General Public License    *
+ * along with this program; if not, write to the Free Software          *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
+ * MA  02110-1301  USA                                                  *
+ ************************************************************************/
+
+// Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
+require_once("inc/libs/security_functions.php");
+
+// Init "action" and "what"
+global $what, $action;
+$GLOBALS['what'] = ""; $GLOBALS['action'] = "";
+if (!empty($_GET['action'])) $GLOBALS['action'] = secureString($_GET['action']);
+if (!empty($_GET['what'])) $GLOBALS['what'] = secureString($_GET['what']);
+
+// Set module
+$GLOBALS['module'] = "doubler";
+$GLOBALS['refid'] = 0;
+$CSS = "0";
+
+// Load the required file(s)
+require ("inc/config.php");
+
+// Is the script installed?
+if (defined('mxchange_installed') && (mxchange_installed))
+{
+       // Probe for referral ID
+       if (!empty($_GET['refid'])) $GLOBALS['refid'] = bigintval($_GET['refid']);
+
+       // Probe for nickname extension and if a nickname was supplied by URL
+       $probe_nickname = ((EXT_IS_ACTIVE("nickname")) && (("".round($GLOBALS['refid'])."") != $GLOBALS['refid']));
+       if ($probe_nickname)
+       {
+               // Nickname in URL, so load the ID
+               $result = SQL_QUERY_ESC("SELECT userid, status FROM "._MYSQL_PREFIX."_user_data WHERE nickname='%s' LIMIT 1",
+                array(bigintval($GLOBALS['refid'])), __FILE__, __LINE__);
+       }
+        else
+       {
+               // Direct userid entered
+               $result = SQL_QUERY_ESC("SELECT userid, status FROM "._MYSQL_PREFIX."_user_data WHERE userid=%d LIMIT 1",
+                array(bigintval($GLOBALS['refid'])), __FILE__, __LINE__);
+       }
+
+       // Load data
+       list($rid, $status_ref) = SQL_FETCHROW($result);
+       $GLOBALS['refid'] = bigintval($rid);
+
+       // Free memory
+       SQL_FREERESULT($result);
+       $uid = 0;
+
+       // If no account was found set default refid and status to CONFIRMED
+       if (empty($GLOBALS['refid'])) { $GLOBALS['refid'] = $CONFIG['def_refid']; $status = "CONFIRMED"; }
+
+       // Begin with doubler script...
+       if (isset($_POST['ok']))
+       {
+               // Secure points (so only integer/double values are allowed
+               $_POST['points'] = bigintval($_POST['points']);
+
+               // Begin with doubling process
+               if ((!empty($_POST['userid'])) && (!empty($_POST['pass'])) && (!empty($_POST['points'])))
+               {
+                       // Probe for nickname extension and if a nickname was entered
+                       $probe_nickname = ((EXT_IS_ACTIVE("nickname")) && (("".round($_POST['userid'])."") != $_POST['userid']));
+                       if ($probe_nickname)
+                       {
+                               // Nickname in URL, so load the ID
+                               $result = SQL_QUERY_ESC("SELECT userid, status, password FROM "._MYSQL_PREFIX."_user_data WHERE nickname='%s' LIMIT 1",
+                                array($_POST['userid']), __FILE__, __LINE__);
+                       }
+                        else
+                       {
+                               // Direct userid entered
+                               $result = SQL_QUERY_ESC("SELECT userid, status, password FROM "._MYSQL_PREFIX."_user_data WHERE userid=%d LIMIT 1",
+                                array(bigintval($_POST['userid'])), __FILE__, __LINE__);
+                       }
+
+                       // Load data
+                       list($uid, $status, $password) = SQL_FETCHROW($result);
+                       $uid = bigintval($uid);
+
+                       // Free result
+                       SQL_FREERESULT($result);
+
+                       // Remove any dots and unwanted chars from the points
+                       $_POST['points'] = bigintval(round(str_replace(",", ".", $_POST['points'])));
+
+                       // Probe for enough points
+                       $probe_points = (($_POST['points'] >= $CONFIG['doubler_min']) && ($_POST['points'] <= $CONFIG['doubler_max']));
+
+                       // Check all together
+                       if ((!empty($uid)) && ($password == generateHash($_POST['pass'], substr($password, 0, -40))) && ($status == "CONFIRMED") && ($probe_points))
+                       {
+                               // Nickname resolved to a unique userid or direct userid entered by the member
+                               $DOUBLER_UID = $uid;
+
+                               // Calulcate points
+                               $POINTS = GET_TOTAL_DATA($uid, "user_points", "points") - GET_TOTAL_DATA($uid, "user_data", "used_points");
+
+                               // So let's continue with probing his points amount
+                               if (($POINTS - $CONFIG['doubler_left'] - $_POST['points'] * $CONFIG['doubler_charge']) >= 0)
+                               {
+                                       // Enough points are left so let's continue with the doubling process
+                                       // Create doubling "account" width *DOUBLED* points
+                                       $result = SQL_QUERY_ESC("INSERT INTO "._MYSQL_PREFIX."_doubler (userid, refid, points, remote_ip, timemark, completed, is_ref) VALUES ('%s', '%s', '%s', '".$_SERVER['REMOTE_ADDR']."', UNIX_TIMESTAMP(), 'N', 'N')",
+                                        array($uid, bigintval($GLOBALS['refid']), bigintval($_POST['points'] * 2)), __FILE__, __LINE__);
+
+                                       // Subtract entered points
+                                       $result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_user_data SET used_points=used_points+%s WHERE userid=%d LIMIT 1",
+                                        array($_POST['points'], $uid), __FILE__, __LINE__);
+
+                                       // Update mediadata as well
+                                       if (GET_EXT_VERSION("mediadata") >= "0.0.4")
+                                       {
+                                               // Update database
+                                               MEDIA_UPDATE_ENTRY(array("total_points"), "sub", $_POST['points']);
+                                       }
+
+                                       // Add points to "total payed" including charge
+                                       $points = $_POST['points'] - $_POST['points'] * $CONFIG['doubler_charge'];
+                                       $result = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_config SET doubler_points=doubler_points+%s WHERE config='0' LIMIT 1",
+                                        array($points), __FILE__, __LINE__);
+                                       $CONFIG['doubler_points'] += $points;
+
+                                       // Destroy cache
+                                       if (GET_EXT_VERSION("cache") >= "0.1.2")
+                                       {
+                                               if ($CACHE->cache_file("config", true)) $CACHE->cache_destroy();
+                                       }
+
+                                       // Add second line for the referral but only when uid != refid
+                                       if (($GLOBALS['refid'] > 0) && ($GLOBALS['refid'] != $uid))
+                                       {
+                                               // Okay add a refid line and apply refid percents
+                                               $result = SQL_QUERY_ESC("INSERT INTO "._MYSQL_PREFIX."_doubler (userid, refid, points, remote_ip, timemark, completed, is_ref) VALUES ('%s', '0', '%s', '".$_SERVER['REMOTE_ADDR']."', UNIX_TIMESTAMP(), 'N', 'Y')",
+                                                array(bigintval($GLOBALS['refid']), bigintval($_POST['points'] * 2 * $CONFIG['doubler_ref'])), __FILE__, __LINE__);
+
+                                               // And that's why we dont't want to you more than one referral level of doubler-points. ^^^
+                                       }
+
+                                       // Update usage counter
+                                       $result = SQL_QUERY("UPDATE "._MYSQL_PREFIX."_config SET doubler_counter=doubler_counter+1 WHERE config='0' LIMIT 1", __FILE__, __LINE__);
+                                       $CONFIG['doubler_counter']++;
+
+                                       // Set constant
+                                       define('__DOUBLER_MSG', LOAD_TEMPLATE("doubler_reflink", true, $_POST['userid']));
+                               }
+                                else
+                               {
+                                       // Not enougth points left
+                                       define('__ERROR_MSG', DOUBLER_FORM_NO_POINTS_LEFT);
+                               }
+
+                       }
+                        elseif ($status == "CONFIRMED")
+                       {
+                               // Account is unconfirmed!
+                               define('__ERROR_MSG', DOUBLER_FORM_WRONG_PASS);
+                       }
+                        elseif ($status == "UNCONFIRMED")
+                       {
+                               // Account is unconfirmed!
+                               define('__ERROR_MSG', DOUBLER_FORM_STATUS_UNCONFIRMED);
+                       }
+                        elseif ($status == "LOCKED")
+                       {
+                               // Account is locked by admin / holiday!
+                               define('__ERROR_MSG', DOUBLER_FORM_STATUS_LOCKED);
+                       }
+                        elseif ($_POST['points'] < $CONFIG['doubler_min'])
+                       {
+                               // Not enougth points entered
+                               define('__ERROR_MSG', DOUBLER_FORM_POINTS_MIN);
+                       }
+                        elseif ($_POST['points'] > $CONFIG['doubler_max'])
+                       {
+                               // Too much points entered
+                               define('__ERROR_MSG', DOUBLER_FORM_POINTS_MAX);
+                       }
+                        elseif ($probe_nickname)
+                       {
+                               // Cannot resolv nickname -> userid
+                               define('__ERROR_MSG', DOUBLER_FORM_404_NICKNAME);
+                       }
+                        else
+                       {
+                               // Wrong password or account not found
+                               define('__ERROR_MSG', DOUBLER_FORM_404_MEMBER);
+                       }
+               }
+                elseif (empty($_POST['userid']))
+               {
+                       // Login not entered
+                       define('__ERROR_MSG', DOUBLER_FORM_404_LOGIN);
+               }
+                elseif (empty($_POST['pass']))
+               {
+                       // Password not entered
+                       define('__ERROR_MSG', DOUBLER_FORM_404_PASSWORD);
+               }
+                elseif (empty($_POST['points']))
+               {
+                       // points not entered
+                       define('__ERROR_MSG', DOUBLER_FORM_404_POINTS);
+               }
+       }
+
+       // Set messages to nothing
+       if (!defined('__DOUBLER_MSG')) define('__DOUBLER_MSG', "");
+       if (!defined('__ERROR_MSG'))   define('__ERROR_MSG'  , "");
+
+       // Shall I check for points immediately?
+       if ($CONFIG['doubler_send_mode'] == "DIRECT") require(PATH."inc/doubler_send.php");
+
+       // Output header
+       include(PATH."inc/header.php");
+
+       // Banner in text
+       define('__DOUBLER_BANNER', LOAD_TEMPLATE("doubler_banner", true));
+
+       // Load header/footer templates
+       define('__DOUBLER_HEADER', LOAD_TEMPLATE("doubler_header", true));
+       define('__DOUBLER_FOOTER', LOAD_TEMPLATE("doubler_footer", true));
+
+       if (!empty($uid))
+       {
+               // Transfer userid/nickname to constant
+               define('__REFID', $uid);
+       }
+        elseif (!empty($GLOBALS['refid']))
+       {
+               // Transfer userid/nickname to constant
+               define('__REFID', $GLOBALS['refid']);
+       }
+        else
+       {
+               // Transfer default refid to constant
+               define('__REFID', $CONFIG['def_refid']);
+       }
+
+       // Percent values etc.
+       define('__CHARGE_VALUE', TRANSLATE_COMMA($CONFIG['doubler_charge'] * 100));
+       define('__REF_VALUE'   , TRANSLATE_COMMA($CONFIG['doubler_ref'] * 100));
+       define('__TOTAL_VALUE' , TRANSLATE_COMMA($CONFIG['doubler_points']));
+       define('__MIN_VALUE'   , TRANSLATE_COMMA($CONFIG['doubler_min']));
+       define('__MAX_VALUE'   , TRANSLATE_COMMA($CONFIG['doubler_max']));
+
+       // Text "Enter login"
+       if (EXT_IS_ACTIVE("nickname"))
+       {
+               // Choose login/nickname
+               define('DOUBLER_ENTER_LOGIN', GUEST_ENTER_LOGIN_NICKNAME);
+       }
+        else
+       {
+               // Simple login ID
+               define('DOUBLER_ENTER_LOGIN', GUEST_ENTER_LOGIN);
+       }
+
+       // Which mail-send-mode did the admin setup?
+       switch ($CONFIG['doubler_send_mode'])
+       {
+       case "DIRECT":
+               define('DOUBLER_PAYOUT_TIME', DOUBLER_PAYOUT_TIME_DIRECT);
+               break;
+
+       case "RESET":
+               define('DOUBLER_PAYOUT_TIME', DOUBLER_PAYOUT_TIME_RESET);
+               break;
+       }
+
+       // Generate table with already payed out doubles
+       define('__DOUBLER_PAYOUT_HISTORY', DOUBLER_GENERATE_TABLE("0", "Y", "N", "DESC"));
+
+       // Generate timemark
+       define('__TIMEOUT_MARK', CREATE_FANCY_TIME($CONFIG['doubler_timeout']));
+
+       // Usage counter
+       define('__DOUBLER_COUNTER', $CONFIG['doubler_counter']);
+
+       // Points left to doubler
+       define('__LEFT_VALUE', TRANSLATE_COMMA(DOUBLER_GET_TOTAL_POINTS_LEFT()));
+
+       // Output neccessary form for this
+       LOAD_TEMPLATE("doubler_index");
+
+       // Output footer
+       include(PATH."inc/footer.php");
+}
+ else
+{
+       // You have to configure first!
+       LOAD_URL(URL."/install.php");
+}
+
+// Really all done here... ;-)
+?>
index bedf3aa60778da643551e6878355b594daf39908..773deaa172ba3458b4426863b2ae0f3cd5a6fd25 100644 (file)
@@ -1,67 +1,67 @@
-<?php\r
-/************************************************************************\r
- * MXChange v0.2.1                                    Start: 10/12/2003 *\r
- * ===============                              Last change: 10/12/2004 *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * File              : img.php                                          *\r
- * -------------------------------------------------------------------- *\r
- * Short description : Image code for multi-purposes                    *\r
- * -------------------------------------------------------------------- *\r
- * Kurzbeschreibung  : Code-Bild fuer verschiedene Zwecke               *\r
- * -------------------------------------------------------------------- *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * Copyright (c) 2003 - 2008 by Roland Haeder                           *\r
- * For more information visit: http://www.mxchange.org                  *\r
- *                                                                      *\r
- * This program is free software; you can redistribute it and/or modify *\r
- * it under the terms of the GNU General Public License as published by *\r
- * the Free Software Foundation; either version 2 of the License, or    *\r
- * (at your option) any later version.                                  *\r
- *                                                                      *\r
- * This program is distributed in the hope that it will be useful,      *\r
- * but WITHOUT ANY WARRANTY; without even the implied warranty of       *\r
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *\r
- * GNU General Public License for more details.                         *\r
- *                                                                      *\r
- * You should have received a copy of the GNU General Public License    *\r
- * along with this program; if not, write to the Free Software          *\r
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *\r
- * MA  02110-1301  USA                                                  *\r
- ************************************************************************/\r
-\r
-// Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )\r
-require_once("inc/libs/security_functions.php");\r
-\r
-// Init "action" and "what"\r
-global $what, $action;\r
-$GLOBALS['what'] = ""; $GLOBALS['action'] = "";\r
-if (!empty($_GET['action'])) $GLOBALS['action'] = secureString($_GET['action']);\r
-if (!empty($_GET['what'])) $GLOBALS['what'] = secureString($_GET['what']);\r
-\r
-// Set�module\r
-$GLOBALS['module'] = "img"; $CSS = -1;\r
-\r
-// Load the required file(s)\r
-require ("inc/config.php");\r
-\r
-if (defined('mxchange_installed') && (mxchange_installed))\r
-{\r
-       if (!empty($_GET['code']))\r
-       {\r
-               // Generate image\r
-               GENERATE_IMAGE(bigintval($_GET['code']));\r
-       }\r
-}\r
- else\r
-{\r
-       // You have to configure first!\r
-       LOAD_URL("install.php");\r
-}\r
-\r
-// Really all done here... ;-)\r
-die();\r
-\r
-//\r
-?>\r
+<?php
+/************************************************************************
+ * MXChange v0.2.1                                    Start: 10/12/2003 *
+ * ===============                              Last change: 10/12/2004 *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * File              : img.php                                          *
+ * -------------------------------------------------------------------- *
+ * Short description : Image code for multi-purposes                    *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung  : Code-Bild fuer verschiedene Zwecke               *
+ * -------------------------------------------------------------------- *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2008 by Roland Haeder                           *
+ * For more information visit: http://www.mxchange.org                  *
+ *                                                                      *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or    *
+ * (at your option) any later version.                                  *
+ *                                                                      *
+ * This program is distributed in the hope that it will be useful,      *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of       *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *
+ * GNU General Public License for more details.                         *
+ *                                                                      *
+ * You should have received a copy of the GNU General Public License    *
+ * along with this program; if not, write to the Free Software          *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
+ * MA  02110-1301  USA                                                  *
+ ************************************************************************/
+
+// Load security stuff here (Oh, I hope this is not unsecure? Am I paranoia??? ;-) )
+require_once("inc/libs/security_functions.php");
+
+// Init "action" and "what"
+global $what, $action;
+$GLOBALS['what'] = ""; $GLOBALS['action'] = "";
+if (!empty($_GET['action'])) $GLOBALS['action'] = secureString($_GET['action']);
+if (!empty($_GET['what'])) $GLOBALS['what'] = secureString($_GET['what']);
+
+// Set�module
+$GLOBALS['module'] = "img"; $CSS = -1;
+
+// Load the required file(s)
+require ("inc/config.php");
+
+if (defined('mxchange_installed') && (mxchange_installed))
+{
+       if (!empty($_GET['code']))
+       {
+               // Generate image
+               GENERATE_IMAGE(bigintval($_GET['code']));
+       }
+}
+ else
+{
+       // You have to configure first!
+       LOAD_URL("install.php");
+}
+
+// Really all done here... ;-)
+die();
+
+//
+?>
index b9d7e68adb0cdbbc3b31539047bd9d8d49c81949..52ac70472785d03c154d95ed708e9c406884f5ec 100644 (file)
-<?php\r
-/************************************************************************\r
- * MXChange v0.2.1                                    Start: 05/29/2004 *\r
- * ===============                              Last change: 11/26/2004 *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * File              : autopurge.php                                    *\r
- * -------------------------------------------------------------------- *\r
- * Short description : Automatical purging of outdated mail links       *\r
- * -------------------------------------------------------------------- *\r
- * Kurzbeschreibung  : Auto-Loeschung von veralteten Mail-Links         *\r
- * -------------------------------------------------------------------- *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * Copyright (c) 2003 - 2008 by Roland Haeder                           *\r
- * For more information visit: http://www.mxchange.org                  *\r
- *                                                                      *\r
- * This program is free software; you can redistribute it and/or modify *\r
- * it under the terms of the GNU General Public License as published by *\r
- * the Free Software Foundation; either version 2 of the License, or    *\r
- * (at your option) any later version.                                  *\r
- *                                                                      *\r
- * This program is distributed in the hope that it will be useful,      *\r
- * but WITHOUT ANY WARRANTY; without even the implied warranty of       *\r
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *\r
- * GNU General Public License for more details.                         *\r
- *                                                                      *\r
- * You should have received a copy of the GNU General Public License    *\r
- * along with this program; if not, write to the Free Software          *\r
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *\r
- * MA  02110-1301  USA                                                  *\r
- ************************************************************************/\r
-\r
-// Some security stuff...\r
-if (ereg(basename(__FILE__), $_SERVER['PHP_SELF']))\r
-{\r
-       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";\r
-       require($INC);\r
-}\r
-\r
-if (($CONFIG['auto_purge_active'] == "Y") && ($CONFIG['auto_purge'] > 0))\r
-{\r
-       // First calculate the timestamp\r
-       if (function_exists('CREATE_TIME_SELECTIONS'))\r
-       {\r
-               $PURGE = time() - $CONFIG['auto_purge'];\r
-       }\r
-        else\r
-       {\r
-               $PURGE = time() - $CONFIG['auto_purge'] * 24 * 60 * 60;\r
-       }\r
-\r
-       // Init variables\r
-       $admin_points = "0";\r
-\r
-       // Then check for outdated mail order. We don't delete them just the confirmation links will be deleted.\r
-       $result = SQL_QUERY_ESC("SELECT s.id, s.userid, s.pool_id, t.price\r
-FROM "._MYSQL_PREFIX."_user_stats AS s\r
-LEFT JOIN "._MYSQL_PREFIX."_payments AS t\r
-ON s.payment_id=t.id\r
-WHERE s.timestamp_ordered <= %s ORDER BY s.userid",\r
-        array(bigintval($PURGE)), __FILE__, __LINE__);\r
-       if (SQL_NUMROWS($result) > 0)\r
-       {\r
-               // Start deleting procedure\r
-               $uid = "0"; $points = "0";\r
-               while(list($mid, $sender, $pool, $price) = SQL_FETCHROW($result))\r
-               {\r
-                       // Check if confirmation links are purged or not\r
-                       $result_links = SQL_QUERY_ESC("SELECT id FROM "._MYSQL_PREFIX."_user_links WHERE stats_id=%d LIMIT 1",\r
-                        array(bigintval($mid)), __FILE__, __LINE__);\r
-                       if (SQL_NUMROWS($result_links) == 1)\r
-                       {\r
-                               // Free memory\r
-                               SQL_FREERESULT($result_links);\r
-\r
-                               // At least one link was found, enougth to pay back the points\r
-                               if (($uid != $sender) && ($uid > 0) && ($points > 0))\r
-                               {\r
-                                       // Directly add points back to senders account\r
-                                       AUTOPURGE_ADD_POINTS($uid, $points);\r
-                                       $points = "0";\r
-                               }\r
-                               // Add points\r
-                               $uid = $sender; $points += $price; $admin_points += $price;\r
-\r
-                               // Remove confirmation links from queue\r
-                               $result_del = SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_user_links WHERE stats_id=%d",\r
-                                array(bigintval($mid)), __FILE__, __LINE__);\r
-\r
-                               // Update status of order\r
-                               $result_update = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_pool SET data_type='DELETED' WHERE id=%d LIMIT 1",\r
-                                array(bigintval($pool)), __FILE__, __LINE__);\r
-                       }\r
-               }\r
-\r
-               // Add last points to last user account\r
-               if ($points > 0) AUTOPURGE_ADD_POINTS($uid, $points);\r
-       }\r
-\r
-       // Free memory\r
-       SQL_FREERESULT($result);\r
-\r
-       // Is the 'bonus' extension installed and activated?\r
-       if (EXT_IS_ACTIVE("bonus", true))\r
-       {\r
-               // Check for bonus campaigns\r
-               $result = SQL_QUERY_ESC("SELECT id, points FROM "._MYSQL_PREFIX."_bonus WHERE data_type='SEND' AND timestamp <= %s ORDER BY id",\r
-                array(bigintval($PURGE)), __FILE__, __LINE__);\r
-               if (SQL_NUMROWS($result) > 0)\r
-               {\r
-                       // Start deleting procedure\r
-                       $points = "0";\r
-                       while (list($bid, $price) = SQL_FETCHROW($result))\r
-                       {\r
-                               // Check if confirmation links are purged or not\r
-                               $result_links = SQL_QUERY_ESC("SELECT id FROM "._MYSQL_PREFIX."_user_links WHERE bonus_id=%d",\r
-                                array(bigintval($bid)), __FILE__, __LINE__);\r
-                               if (SQL_NUMROWS($result_links) > 0)\r
-                               {\r
-                                       // At least one link was found, enougth to pay back the points\r
-                                       $points += $price * SQL_NUMROWS($result_links);\r
-\r
-                                       // Free memory\r
-                                       SQL_FREERESULT($result_links);\r
-\r
-                                       // Remove confirmation links from queue\r
-                                       $result_del = SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_user_links WHERE bonus_id=%d",\r
-                                        array(bigintval($bid)), __FILE__, __LINE__);\r
-\r
-                                       // Update status of order\r
-                                       $result_update = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_bonus SET data_type='DELETED' WHERE id=%d LIMIT 1",\r
-                                        array(bigintval($bid)), __FILE__, __LINE__);\r
-                               }\r
-                       }\r
-\r
-                       // Add points to jackpot\r
-                       ADD_JACKPOT($points);\r
-\r
-                       // Add points for the admin\r
-                       $admin_points += $points;\r
-               }\r
-\r
-               // Free memory\r
-               SQL_FREERESULT($result);\r
-       }\r
-\r
-       // Add points from deleted accounts to jackpot, but here just add to notify mail\r
-       if ($admin_points > 0)\r
-       {\r
-               // Send mail to admin\r
-               if (GET_EXT_VERSION("admins") >= "0.4.1")\r
-               {\r
-                       SEND_ADMIN_EMAILS_PRO(AUTOPURGE_ADMIN_SUBJECT, "admin_autopurge_points", TRANSLATE_COMMA($points), "0");\r
-               }\r
-                else\r
-               {\r
-                       $msg = LOAD_EMAIL_TEMPLATE("admin_autopurge_points", TRANSLATE_COMMA($points), "0");\r
-                       SEND_ADMIN_EMAILS(AUTOPURGE_ADMIN_SUBJECT, $msg);\r
-               }\r
-       }\r
-}\r
-\r
-// Shall I look for inactive accounts and autopurge inactive accounts?\r
-if ($CONFIG['ap_inactive'] == "Y")\r
-{\r
-       // Ok, let's have a look...\r
-       $since = bigintval(time() - $CONFIG['ap_in_since']);\r
-       $EXCLUDE_LIST = " AND d.userid != c.def_refid";\r
-\r
-       // Check for more extensions\r
-       if (EXT_IS_ACTIVE("beg"))     $EXCLUDE_LIST .= " AND d.userid != c.beg_uid";\r
-       if (EXT_IS_ACTIVE("bonus"))   $EXCLUDE_LIST .= " AND d.userid != c.bonus_uid";\r
-       if (EXT_IS_ACTIVE("doubler")) $EXCLUDE_LIST .= " AND d.userid != c.doubler_uid";\r
-\r
-       // Check for new holiday extension\r
-       if (GET_EXT_VERSION("holiday") >= "0.1.3")\r
-       {\r
-               $EXCLUDE_LIST .= " AND d.holiday_active = 'N'";\r
-       }\r
-\r
-       // Check for all accounts\r
-       $result_inactive = SQL_QUERY_ESC("SELECT DISTINCT d.userid, d.email, d.last_online\r
-FROM "._MYSQL_PREFIX."_user_data AS d, "._MYSQL_PREFIX."_config AS c\r
-WHERE d.status='CONFIRMED' AND d.joined < %s AND d.last_online < %s AND d.ap_notified < %s\r
-".$EXCLUDE_LIST."\r
-ORDER BY d.userid", array($since, $since, $since), __FILE__, __LINE__);\r
-\r
-       if (SQL_NUMROWS($result_inactive) > 0)\r
-       {\r
-               // Prepare variables and constants...\r
-               $UIDs = "";\r
-               define('__INACTIVE_SINCE', ($CONFIG['ap_in_since'] / 60 / 60));\r
-               define('__INACTIVE_TIME' , ($CONFIG['ap_in_time']  / 60 / 60));\r
-\r
-               // Mark found accounts as inactive and send an email\r
-               while(list($uid, $email, $last) = SQL_FETCHROW($result_inactive))\r
-               {\r
-                       // Remember userids for the admin\r
-                       $UIDs .= $uid.", ";\r
-\r
-                       // Get date/time from timestamp\r
-                       $last = MAKE_DATETIME($last, "0");\r
-\r
-                       // Load mail template\r
-                       $msg = LOAD_EMAIL_TEMPLATE("member_autopurge_inactive", $last, bigintval($uid));\r
-                       SEND_EMAIL($email, AUTOPURGE_MEMBER_INACTIVE_SUBJECT, $msg);\r
-\r
-                       // Update this account\r
-                       $result_update = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_user_data SET ap_notified=UNIX_TIMESTAMP() WHERE userid=%d LIMIT 1",\r
-                        array(bigintval($uid)), __FILE__, __LINE__);\r
-               }\r
-\r
-               // Remove last comma\r
-               $UIDs = str_replace(", ", "\n", substr($UIDs, 0, -2));\r
-\r
-               // Send mail notification to admin\r
-               if (GET_EXT_VERSION("admins") >= "0.4.1")\r
-               {\r
-                       SEND_ADMIN_EMAILS_PRO(AUTOPURGE_ADMIN_INACTIVE_SUBJECT, "admin_autopurge_inactive", $UIDs, "");\r
-               }\r
-                else\r
-               {\r
-                       $msg = LOAD_EMAIL_TEMPLATE("admin_autopurge_inactive", $UIDs, "");\r
-                       SEND_ADMIN_EMAILS(AUTOPURGE_ADMIN_INACTIVE_SUBJECT, $msg);\r
-               }\r
-       }\r
-\r
-       // Free memory\r
-       SQL_FREERESULT($result_inactive);\r
-\r
-       // Now let's have a look for inactive accounts we want to delete we newly use the same exclude list\r
-       // here for e.g. excluding holiday users\r
-       $time = bigintval(time() - $CONFIG['ap_in_time']);\r
-       $result_inactive = SQL_QUERY_ESC("SELECT d.userid, d.email, d.last_online\r
-FROM "._MYSQL_PREFIX."_user_data AS d, "._MYSQL_PREFIX."_config AS c\r
-WHERE status='CONFIRMED' AND joined < %s AND last_online< %s AND ap_notified < %s\r
-".$EXCLUDE_LIST."\r
-ORDER BY userid",\r
-        array($since, $since, $time), __FILE__, __LINE__);\r
-       if (SQL_NUMROWS($result_inactive) > 0)\r
-       {\r
-               // Prepare variable...\r
-               $UIDs = "";\r
-\r
-               // Delete inactive accounts\r
-               while (list($uid, $email, $last) = SQL_FETCHROW($result_inactive))\r
-               {\r
-                       // Remember userids for the admin\r
-                       $UIDs .= $uid.", ";\r
-\r
-                       // Get date/time from timestamp\r
-                       $last = MAKE_DATETIME($last, "0");\r
-\r
-                       // Finnaly delete this inactive account\r
-                       DELETE_USER_ACCOUNT(bigintval($uid), LOAD_EMAIL_TEMPLATE("member_autopurge_delete", $last, ""));\r
-               }\r
-\r
-               // Remove last comma\r
-               $UIDs = str_replace(", ", "\n", substr($UIDs, 0, -2));\r
-\r
-               // Send mail notification to admin\r
-               if ($CONFIG['ap_un_mail'] == "Y")\r
-               {\r
-                       if (GET_EXT_VERSION("admins") >= "0.4.1")\r
-                       {\r
-                               SEND_ADMIN_EMAILS_PRO(AUTOPURGE_ADMIN_DELETE_SUBJECT, "admin_autopurge_delete", $UIDs, "");\r
-                       }\r
-                        else\r
-                       {\r
-                               $msg = LOAD_EMAIL_TEMPLATE("admin_autopurge_delete", $UIDs, "");\r
-                               SEND_ADMIN_EMAILS(AUTOPURGE_ADMIN_DELETE_SUBJECT, $msg);\r
-                       }\r
-               }\r
-       }\r
-\r
-       // Free memory\r
-       SQL_FREERESULT($result_inactive);\r
-}\r
-\r
-// Shall I auto-purge unconfirmed accounts?\r
-if ($CONFIG['ap_unconfirmed'] == "Y")\r
-{\r
-       // Init variables and find unconfirmed accounts which I shall auto-purge\r
-       $time = bigintval(time() - $CONFIG['ap_un_time']);\r
-       $result_uncon = SQL_QUERY_ESC("SELECT userid, email, joined FROM "._MYSQL_PREFIX."_user_data WHERE status='UNCONFIRMED' AND joined < %s ORDER BY userid",\r
-        array($time), __FILE__, __LINE__);\r
-       if (SQL_NUMROWS($result_uncon) > 0)\r
-       {\r
-               // Prepare variable...\r
-               $UIDs = "";\r
-               define('__UNCONFIRMED_TIME' , ($CONFIG['ap_un_time']  / 60 / 60));\r
-\r
-               // Delete inactive accounts\r
-               while (list($uid, $email, $joined) = SQL_FETCHROW($result_uncon))\r
-               {\r
-                       // Remember userids for the admin\r
-                       $UIDs .= $uid.", ";\r
-\r
-                       // Get date/time from timestamp\r
-                       $joined = MAKE_DATETIME($joined, "0");\r
-\r
-                       // Finnaly delete this inactive account\r
-                       DELETE_USER_ACCOUNT($uid, LOAD_EMAIL_TEMPLATE("member_autopurge_unconfirmed", $joined, ""));\r
-               }\r
-\r
-               // Remove last comma\r
-               $UIDs = str_replace(", ", "\n", substr($UIDs, 0, -2));\r
-\r
-               // Send mail notification to admin\r
-               if ($CONFIG['ap_un_mail'] == "Y")\r
-               {\r
-                       if (GET_EXT_VERSION("admins") >= "0.4.1")\r
-                       {\r
-                               SEND_ADMIN_EMAILS_PRO(AUTOPURGE_ADMIN_UNCONFIRMED_SUBJECT, "admin_autopurge_unconfirmed", $UIDs, "");\r
-                       }\r
-                        else\r
-                       {\r
-                               $msg = LOAD_EMAIL_TEMPLATE("admin_autopurge_unconfirmed", $UIDs, "");\r
-                               SEND_ADMIN_EMAILS(AUTOPURGE_ADMIN_UNCONFIRMED_SUBJECT, $msg);\r
-                       }\r
-               }\r
-       }\r
-\r
-       // Free memory\r
-       SQL_FREERESULT($result_uncon);\r
-}\r
-\r
-// Check version (must be > 0.0)\r
-if ((GET_EXT_VERSION("task") > "0.0") && ($CONFIG['ap_tasks'] == "Y"))\r
-{\r
-       // Purge deleted tasks (no notification to admin)\r
-       $since = bigintval(time() - $CONFIG['ap_tasks_time']);\r
-       $result = SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_task_system WHERE status='DELETED' AND task_created <= %s",\r
-        array($since), __FILE__, __LINE__);\r
-       $DELETED = SQL_AFFECTEDROWS();\r
-\r
-       if (($DELETED > 0) && ($CONFIG['ap_tasks_mail'] == "Y"))\r
-       {\r
-               // Send out email to admin\r
-               if (GET_EXT_VERSION("admins") >= "0.4.1")\r
-               {\r
-                       SEND_ADMIN_EMAILS_PRO(AUTOPURGE_ADMIN_TASKS_SUBJECT, "admin_autopurge_tsks", $DELETED, "");\r
-               }\r
-                else\r
-               {\r
-                       $msg = LOAD_EMAIL_TEMPLATE("admin_autopurge_tsks", $DELETED, "");\r
-                       SEND_ADMIN_EMAILS(AUTOPURGE_ADMIN_TASKS_SUBJECT, $msg);\r
-               }\r
-       }\r
-}\r
-\r
-// Search for mails from deleted members?\r
-if ($CONFIG['ap_del_mails'])\r
-{\r
-       // Okay, let's check for them...\r
-       $since = bigintval(time() - $CONFIG['ap_dm_timeout']);\r
-       $result_mails = SQL_QUERY_ESC("SELECT sender FROM "._MYSQL_PREFIX."_pool WHERE data_type='DELETED' AND timestamp <= %s ORDER BY sender",\r
-        array($since), __FILE__, __LINE__);\r
-\r
-       // Reset counter...\r
-       $DELETED = 0;\r
-\r
-       // Do we have "purged" mails?\r
-       if (SQL_NUMROWS($result_mails) > 0)\r
-       {\r
-               // Okay, check for their sender's\r
-               while(list($sender) = SQL_FETCHROW($result_mails))\r
-               {\r
-                       // Check now...\r
-                       $fount = SQL_NUMROWS(SQL_QUERY_ESC("SELECT userid FROM "._MYSQL_PREFIX."_user_data WHERE userid=%d LIMIT 1", array(bigintval($sender)), __FILE__, __LINE__));\r
-                       if ($found == 0)\r
-                       {\r
-                               // Okay we found some mails!\r
-                               $result_remove = SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_pool WHERE sender=%d",\r
-                                array(bigintval($sender)), __FILE__, __LINE__);\r
-                               $DELETED += SQL_AFFECTEDROWS();\r
-\r
-                               // Reset query (to prevent possible errors) ...\r
-                               $since = bigintval(time() - $CONFIG['ap_dm_timeout']);\r
-                               $result_mails = SQL_QUERY_ESC("SELECT sender FROM "._MYSQL_PREFIX."_pool WHERE data_type='DELETED' AND timestamp <= %s ORDER BY sender",\r
-                                array($since), __FILE__, __LINE__);\r
-                       }\r
-               }\r
-       }\r
-\r
-       // Free memory\r
-       SQL_FREERESULT($result_mails);\r
-\r
-       // Now let's check for stats entries as well\r
-       $since = bigintval(time() - $CONFIG['ap_dm_timeout']);\r
-       $result_mails = SQL_QUERY_ESC("SELECT sender FROM "._MYSQL_PREFIX."_pool WHERE data_type='DELETED' AND timestamp <= %s ORDER BY sender",\r
-        array($since), __FILE__, __LINE__);\r
-\r
-       // Do we have "purged" mails?\r
-       if (SQL_NUMROWS($result_mails) > 0)\r
-       {\r
-               // Okay, check for their sender's\r
-               while(list($sender) = SQL_FETCHROW($result_mails))\r
-               {\r
-                       // Check now...\r
-                       $found = SQL_NUMROWS(SQL_QUERY_ESC("SELECT userid FROM "._MYSQL_PREFIX."_user_data WHERE userid=%d LIMIT 1", array(bigintval($sender)), __FILE__, __LINE__));\r
-                       if ($found == 0)\r
-                       {\r
-                               // Okay we found some mails!\r
-                               $result_remove = SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_user_stats WHERE sender=%d", array(bigintval($sender)), __FILE__, __LINE__);\r
-                               $DELETED += SQL_AFFECTEDROWS();\r
-\r
-                               // Reset query (to prevent possible errors) ...\r
-                               $since = bigintval(time() - $CONFIG['ap_dm_timeout']);\r
-                               $result_mails = SQL_QUERY_ESC("SELECT sender FROM "._MYSQL_PREFIX."_user_stats WHERE data_type='DELETED' AND timestamp_send <= %s ORDER BY sender",\r
-                                array($since), __FILE__, __LINE__);\r
-                       }\r
-               }\r
-       }\r
-\r
-       // Free memory\r
-       SQL_FREERESULT($result_mails);\r
-\r
-       // Do we have deleted mails and the admin want's to receive a notification\r
-       if (($DELETED > 0) && ($CONFIG['ap_dm_notify'] == "Y"))\r
-       {\r
-               // Send out email to admin\r
-               if (GET_EXT_VERSION("admins") >= "0.4.1")\r
-               {\r
-                       SEND_ADMIN_EMAILS_PRO(AUTOPURGE_ADMIN_DEL_MAILS_SUBJECT, "admin_autopurge_del_mails", $DELETED, "");\r
-               }\r
-                else\r
-               {\r
-                       $msg = LOAD_EMAIL_TEMPLATE("admin_autopurge_del_mails", $DELETED, "");\r
-                       SEND_ADMIN_EMAILS(AUTOPURGE_ADMIN_DEL_MAILS_SUBJECT, $msg);\r
-               }\r
-       }\r
-}\r
-\r
-if (EXT_IS_ACTIVE("rallye"))\r
-{\r
-       // Check expired rallyes (hard-coded 3 days limit for displaying expired rallyes!)\r
-       require_once(PATH."inc/libs/rallye_functions.php");\r
-       RALLYE_DELETE_EXPIRED_RALLYES();\r
-}\r
-//\r
-if (EXT_IS_ACTIVE("bonus"))\r
-{\r
-       // Check for expired turbo bonus lines\r
-       require_once(PATH."inc/libs/bonus_functions.php");\r
-       BONUS_PURGE_EXPIRED_TURBO_BONUS();\r
-}\r
-//\r
-?>\r
+<?php
+/************************************************************************
+ * MXChange v0.2.1                                    Start: 05/29/2004 *
+ * ===============                              Last change: 11/26/2004 *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * File              : autopurge.php                                    *
+ * -------------------------------------------------------------------- *
+ * Short description : Automatical purging of outdated mail links       *
+ * -------------------------------------------------------------------- *
+ * Kurzbeschreibung  : Auto-Loeschung von veralteten Mail-Links         *
+ * -------------------------------------------------------------------- *
+ *                                                                      *
+ * -------------------------------------------------------------------- *
+ * Copyright (c) 2003 - 2008 by Roland Haeder                           *
+ * For more information visit: http://www.mxchange.org                  *
+ *                                                                      *
+ * This program is free software; you can redistribute it and/or modify *
+ * it under the terms of the GNU General Public License as published by *
+ * the Free Software Foundation; either version 2 of the License, or    *
+ * (at your option) any later version.                                  *
+ *                                                                      *
+ * This program is distributed in the hope that it will be useful,      *
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of       *
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *
+ * GNU General Public License for more details.                         *
+ *                                                                      *
+ * You should have received a copy of the GNU General Public License    *
+ * along with this program; if not, write to the Free Software          *
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *
+ * MA  02110-1301  USA                                                  *
+ ************************************************************************/
+
+// Some security stuff...
+if (ereg(basename(__FILE__), $_SERVER['PHP_SELF']))
+{
+       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";
+       require($INC);
+}
+
+if (($CONFIG['auto_purge_active'] == "Y") && ($CONFIG['auto_purge'] > 0))
+{
+       // First calculate the timestamp
+       if (function_exists('CREATE_TIME_SELECTIONS'))
+       {
+               $PURGE = time() - $CONFIG['auto_purge'];
+       }
+        else
+       {
+               $PURGE = time() - $CONFIG['auto_purge'] * 24 * 60 * 60;
+       }
+
+       // Init variables
+       $admin_points = "0";
+
+       // Then check for outdated mail order. We don't delete them just the confirmation links will be deleted.
+       $result = SQL_QUERY_ESC("SELECT s.id, s.userid, s.pool_id, t.price
+FROM "._MYSQL_PREFIX."_user_stats AS s
+LEFT JOIN "._MYSQL_PREFIX."_payments AS t
+ON s.payment_id=t.id
+WHERE s.timestamp_ordered <= %s ORDER BY s.userid",
+        array(bigintval($PURGE)), __FILE__, __LINE__);
+       if (SQL_NUMROWS($result) > 0)
+       {
+               // Start deleting procedure
+               $uid = "0"; $points = "0";
+               while(list($mid, $sender, $pool, $price) = SQL_FETCHROW($result))
+               {
+                       // Check if confirmation links are purged or not
+                       $result_links = SQL_QUERY_ESC("SELECT id FROM "._MYSQL_PREFIX."_user_links WHERE stats_id=%d LIMIT 1",
+                        array(bigintval($mid)), __FILE__, __LINE__);
+                       if (SQL_NUMROWS($result_links) == 1)
+                       {
+                               // Free memory
+                               SQL_FREERESULT($result_links);
+
+                               // At least one link was found, enougth to pay back the points
+                               if (($uid != $sender) && ($uid > 0) && ($points > 0))
+                               {
+                                       // Directly add points back to senders account
+                                       AUTOPURGE_ADD_POINTS($uid, $points);
+                                       $points = "0";
+                               }
+                               // Add points
+                               $uid = $sender; $points += $price; $admin_points += $price;
+
+                               // Remove confirmation links from queue
+                               $result_del = SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_user_links WHERE stats_id=%d",
+                                array(bigintval($mid)), __FILE__, __LINE__);
+
+                               // Update status of order
+                               $result_update = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_pool SET data_type='DELETED' WHERE id=%d LIMIT 1",
+                                array(bigintval($pool)), __FILE__, __LINE__);
+                       }
+               }
+
+               // Add last points to last user account
+               if ($points > 0) AUTOPURGE_ADD_POINTS($uid, $points);
+       }
+
+       // Free memory
+       SQL_FREERESULT($result);
+
+       // Is the 'bonus' extension installed and activated?
+       if (EXT_IS_ACTIVE("bonus", true))
+       {
+               // Check for bonus campaigns
+               $result = SQL_QUERY_ESC("SELECT id, points FROM "._MYSQL_PREFIX."_bonus WHERE data_type='SEND' AND timestamp <= %s ORDER BY id",
+                array(bigintval($PURGE)), __FILE__, __LINE__);
+               if (SQL_NUMROWS($result) > 0)
+               {
+                       // Start deleting procedure
+                       $points = "0";
+                       while (list($bid, $price) = SQL_FETCHROW($result))
+                       {
+                               // Check if confirmation links are purged or not
+                               $result_links = SQL_QUERY_ESC("SELECT id FROM "._MYSQL_PREFIX."_user_links WHERE bonus_id=%d",
+                                array(bigintval($bid)), __FILE__, __LINE__);
+                               if (SQL_NUMROWS($result_links) > 0)
+                               {
+                                       // At least one link was found, enougth to pay back the points
+                                       $points += $price * SQL_NUMROWS($result_links);
+
+                                       // Free memory
+                                       SQL_FREERESULT($result_links);
+
+                                       // Remove confirmation links from queue
+                                       $result_del = SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_user_links WHERE bonus_id=%d",
+                                        array(bigintval($bid)), __FILE__, __LINE__);
+
+                                       // Update status of order
+                                       $result_update = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_bonus SET data_type='DELETED' WHERE id=%d LIMIT 1",
+                                        array(bigintval($bid)), __FILE__, __LINE__);
+                               }
+                       }
+
+                       // Add points to jackpot
+                       ADD_JACKPOT($points);
+
+                       // Add points for the admin
+                       $admin_points += $points;
+               }
+
+               // Free memory
+               SQL_FREERESULT($result);
+       }
+
+       // Add points from deleted accounts to jackpot, but here just add to notify mail
+       if ($admin_points > 0)
+       {
+               // Send mail to admin
+               if (GET_EXT_VERSION("admins") >= "0.4.1")
+               {
+                       SEND_ADMIN_EMAILS_PRO(AUTOPURGE_ADMIN_SUBJECT, "admin_autopurge_points", TRANSLATE_COMMA($points), "0");
+               }
+                else
+               {
+                       $msg = LOAD_EMAIL_TEMPLATE("admin_autopurge_points", TRANSLATE_COMMA($points), "0");
+                       SEND_ADMIN_EMAILS(AUTOPURGE_ADMIN_SUBJECT, $msg);
+               }
+       }
+}
+
+// Shall I look for inactive accounts and autopurge inactive accounts?
+if ($CONFIG['ap_inactive'] == "Y")
+{
+       // Ok, let's have a look...
+       $since = bigintval(time() - $CONFIG['ap_in_since']);
+       $EXCLUDE_LIST = " AND d.userid != c.def_refid";
+
+       // Check for more extensions
+       if (EXT_IS_ACTIVE("beg"))     $EXCLUDE_LIST .= " AND d.userid != c.beg_uid";
+       if (EXT_IS_ACTIVE("bonus"))   $EXCLUDE_LIST .= " AND d.userid != c.bonus_uid";
+       if (EXT_IS_ACTIVE("doubler")) $EXCLUDE_LIST .= " AND d.userid != c.doubler_uid";
+
+       // Check for new holiday extension
+       if (GET_EXT_VERSION("holiday") >= "0.1.3")
+       {
+               $EXCLUDE_LIST .= " AND d.holiday_active = 'N'";
+       }
+
+       // Check for all accounts
+       $result_inactive = SQL_QUERY_ESC("SELECT DISTINCT d.userid, d.email, d.last_online
+FROM "._MYSQL_PREFIX."_user_data AS d, "._MYSQL_PREFIX."_config AS c
+WHERE d.status='CONFIRMED' AND d.joined < %s AND d.last_online < %s AND d.ap_notified < %s
+".$EXCLUDE_LIST."
+ORDER BY d.userid", array($since, $since, $since), __FILE__, __LINE__);
+
+       if (SQL_NUMROWS($result_inactive) > 0)
+       {
+               // Prepare variables and constants...
+               $UIDs = "";
+               define('__INACTIVE_SINCE', ($CONFIG['ap_in_since'] / 60 / 60));
+               define('__INACTIVE_TIME' , ($CONFIG['ap_in_time']  / 60 / 60));
+
+               // Mark found accounts as inactive and send an email
+               while(list($uid, $email, $last) = SQL_FETCHROW($result_inactive))
+               {
+                       // Remember userids for the admin
+                       $UIDs .= $uid.", ";
+
+                       // Get date/time from timestamp
+                       $last = MAKE_DATETIME($last, "0");
+
+                       // Load mail template
+                       $msg = LOAD_EMAIL_TEMPLATE("member_autopurge_inactive", $last, bigintval($uid));
+                       SEND_EMAIL($email, AUTOPURGE_MEMBER_INACTIVE_SUBJECT, $msg);
+
+                       // Update this account
+                       $result_update = SQL_QUERY_ESC("UPDATE "._MYSQL_PREFIX."_user_data SET ap_notified=UNIX_TIMESTAMP() WHERE userid=%d LIMIT 1",
+                        array(bigintval($uid)), __FILE__, __LINE__);
+               }
+
+               // Remove last comma
+               $UIDs = str_replace(", ", "\n", substr($UIDs, 0, -2));
+
+               // Send mail notification to admin
+               if (GET_EXT_VERSION("admins") >= "0.4.1")
+               {
+                       SEND_ADMIN_EMAILS_PRO(AUTOPURGE_ADMIN_INACTIVE_SUBJECT, "admin_autopurge_inactive", $UIDs, "");
+               }
+                else
+               {
+                       $msg = LOAD_EMAIL_TEMPLATE("admin_autopurge_inactive", $UIDs, "");
+                       SEND_ADMIN_EMAILS(AUTOPURGE_ADMIN_INACTIVE_SUBJECT, $msg);
+               }
+       }
+
+       // Free memory
+       SQL_FREERESULT($result_inactive);
+
+       // Now let's have a look for inactive accounts we want to delete we newly use the same exclude list
+       // here for e.g. excluding holiday users
+       $time = bigintval(time() - $CONFIG['ap_in_time']);
+       $result_inactive = SQL_QUERY_ESC("SELECT d.userid, d.email, d.last_online
+FROM "._MYSQL_PREFIX."_user_data AS d, "._MYSQL_PREFIX."_config AS c
+WHERE status='CONFIRMED' AND joined < %s AND last_online< %s AND ap_notified < %s
+".$EXCLUDE_LIST."
+ORDER BY userid",
+        array($since, $since, $time), __FILE__, __LINE__);
+       if (SQL_NUMROWS($result_inactive) > 0)
+       {
+               // Prepare variable...
+               $UIDs = "";
+
+               // Delete inactive accounts
+               while (list($uid, $email, $last) = SQL_FETCHROW($result_inactive))
+               {
+                       // Remember userids for the admin
+                       $UIDs .= $uid.", ";
+
+                       // Get date/time from timestamp
+                       $last = MAKE_DATETIME($last, "0");
+
+                       // Finnaly delete this inactive account
+                       DELETE_USER_ACCOUNT(bigintval($uid), LOAD_EMAIL_TEMPLATE("member_autopurge_delete", $last, ""));
+               }
+
+               // Remove last comma
+               $UIDs = str_replace(", ", "\n", substr($UIDs, 0, -2));
+
+               // Send mail notification to admin
+               if ($CONFIG['ap_un_mail'] == "Y")
+               {
+                       if (GET_EXT_VERSION("admins") >= "0.4.1")
+                       {
+                               SEND_ADMIN_EMAILS_PRO(AUTOPURGE_ADMIN_DELETE_SUBJECT, "admin_autopurge_delete", $UIDs, "");
+                       }
+                        else
+                       {
+                               $msg = LOAD_EMAIL_TEMPLATE("admin_autopurge_delete", $UIDs, "");
+                               SEND_ADMIN_EMAILS(AUTOPURGE_ADMIN_DELETE_SUBJECT, $msg);
+                       }
+               }
+       }
+
+       // Free memory
+       SQL_FREERESULT($result_inactive);
+}
+
+// Shall I auto-purge unconfirmed accounts?
+if ($CONFIG['ap_unconfirmed'] == "Y")
+{
+       // Init variables and find unconfirmed accounts which I shall auto-purge
+       $time = bigintval(time() - $CONFIG['ap_un_time']);
+       $result_uncon = SQL_QUERY_ESC("SELECT userid, email, joined FROM "._MYSQL_PREFIX."_user_data WHERE status='UNCONFIRMED' AND joined < %s ORDER BY userid",
+        array($time), __FILE__, __LINE__);
+       if (SQL_NUMROWS($result_uncon) > 0)
+       {
+               // Prepare variable...
+               $UIDs = "";
+               define('__UNCONFIRMED_TIME' , ($CONFIG['ap_un_time']  / 60 / 60));
+
+               // Delete inactive accounts
+               while (list($uid, $email, $joined) = SQL_FETCHROW($result_uncon))
+               {
+                       // Remember userids for the admin
+                       $UIDs .= $uid.", ";
+
+                       // Get date/time from timestamp
+                       $joined = MAKE_DATETIME($joined, "0");
+
+                       // Finnaly delete this inactive account
+                       DELETE_USER_ACCOUNT($uid, LOAD_EMAIL_TEMPLATE("member_autopurge_unconfirmed", $joined, ""));
+               }
+
+               // Remove last comma
+               $UIDs = str_replace(", ", "\n", substr($UIDs, 0, -2));
+
+               // Send mail notification to admin
+               if ($CONFIG['ap_un_mail'] == "Y")
+               {
+                       if (GET_EXT_VERSION("admins") >= "0.4.1")
+                       {
+                               SEND_ADMIN_EMAILS_PRO(AUTOPURGE_ADMIN_UNCONFIRMED_SUBJECT, "admin_autopurge_unconfirmed", $UIDs, "");
+                       }
+                        else
+                       {
+                               $msg = LOAD_EMAIL_TEMPLATE("admin_autopurge_unconfirmed", $UIDs, "");
+                               SEND_ADMIN_EMAILS(AUTOPURGE_ADMIN_UNCONFIRMED_SUBJECT, $msg);
+                       }
+               }
+       }
+
+       // Free memory
+       SQL_FREERESULT($result_uncon);
+}
+
+// Check version (must be > 0.0)
+if ((GET_EXT_VERSION("task") > "0.0") && ($CONFIG['ap_tasks'] == "Y"))
+{
+       // Purge deleted tasks (no notification to admin)
+       $since = bigintval(time() - $CONFIG['ap_tasks_time']);
+       $result = SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_task_system WHERE status='DELETED' AND task_created <= %s",
+        array($since), __FILE__, __LINE__);
+       $DELETED = SQL_AFFECTEDROWS();
+
+       if (($DELETED > 0) && ($CONFIG['ap_tasks_mail'] == "Y"))
+       {
+               // Send out email to admin
+               if (GET_EXT_VERSION("admins") >= "0.4.1")
+               {
+                       SEND_ADMIN_EMAILS_PRO(AUTOPURGE_ADMIN_TASKS_SUBJECT, "admin_autopurge_tsks", $DELETED, "");
+               }
+                else
+               {
+                       $msg = LOAD_EMAIL_TEMPLATE("admin_autopurge_tsks", $DELETED, "");
+                       SEND_ADMIN_EMAILS(AUTOPURGE_ADMIN_TASKS_SUBJECT, $msg);
+               }
+       }
+}
+
+// Search for mails from deleted members?
+if ($CONFIG['ap_del_mails'])
+{
+       // Okay, let's check for them...
+       $since = bigintval(time() - $CONFIG['ap_dm_timeout']);
+       $result_mails = SQL_QUERY_ESC("SELECT sender FROM "._MYSQL_PREFIX."_pool WHERE data_type='DELETED' AND timestamp <= %s ORDER BY sender",
+        array($since), __FILE__, __LINE__);
+
+       // Reset counter...
+       $DELETED = 0;
+
+       // Do we have "purged" mails?
+       if (SQL_NUMROWS($result_mails) > 0)
+       {
+               // Okay, check for their sender's
+               while(list($sender) = SQL_FETCHROW($result_mails))
+               {
+                       // Check now...
+                       $fount = SQL_NUMROWS(SQL_QUERY_ESC("SELECT userid FROM "._MYSQL_PREFIX."_user_data WHERE userid=%d LIMIT 1", array(bigintval($sender)), __FILE__, __LINE__));
+                       if ($found == 0)
+                       {
+                               // Okay we found some mails!
+                               $result_remove = SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_pool WHERE sender=%d",
+                                array(bigintval($sender)), __FILE__, __LINE__);
+                               $DELETED += SQL_AFFECTEDROWS();
+
+                               // Reset query (to prevent possible errors) ...
+                               $since = bigintval(time() - $CONFIG['ap_dm_timeout']);
+                               $result_mails = SQL_QUERY_ESC("SELECT sender FROM "._MYSQL_PREFIX."_pool WHERE data_type='DELETED' AND timestamp <= %s ORDER BY sender",
+                                array($since), __FILE__, __LINE__);
+                       }
+               }
+       }
+
+       // Free memory
+       SQL_FREERESULT($result_mails);
+
+       // Now let's check for stats entries as well
+       $since = bigintval(time() - $CONFIG['ap_dm_timeout']);
+       $result_mails = SQL_QUERY_ESC("SELECT sender FROM "._MYSQL_PREFIX."_pool WHERE data_type='DELETED' AND timestamp <= %s ORDER BY sender",
+        array($since), __FILE__, __LINE__);
+
+       // Do we have "purged" mails?
+       if (SQL_NUMROWS($result_mails) > 0)
+       {
+               // Okay, check for their sender's
+               while(list($sender) = SQL_FETCHROW($result_mails))
+               {
+                       // Check now...
+                       $found = SQL_NUMROWS(SQL_QUERY_ESC("SELECT userid FROM "._MYSQL_PREFIX."_user_data WHERE userid=%d LIMIT 1", array(bigintval($sender)), __FILE__, __LINE__));
+                       if ($found == 0)
+                       {
+                               // Okay we found some mails!
+                               $result_remove = SQL_QUERY_ESC("DELETE LOW_PRIORITY FROM "._MYSQL_PREFIX."_user_stats WHERE sender=%d", array(bigintval($sender)), __FILE__, __LINE__);
+                               $DELETED += SQL_AFFECTEDROWS();
+
+                               // Reset query (to prevent possible errors) ...
+                               $since = bigintval(time() - $CONFIG['ap_dm_timeout']);
+                               $result_mails = SQL_QUERY_ESC("SELECT sender FROM "._MYSQL_PREFIX."_user_stats WHERE data_type='DELETED' AND timestamp_send <= %s ORDER BY sender",
+                                array($since), __FILE__, __LINE__);
+                       }
+               }
+       }
+
+       // Free memory
+       SQL_FREERESULT($result_mails);
+
+       // Do we have deleted mails and the admin want's to receive a notification
+       if (($DELETED > 0) && ($CONFIG['ap_dm_notify'] == "Y"))
+       {
+               // Send out email to admin
+               if (GET_EXT_VERSION("admins") >= "0.4.1")
+               {
+                       SEND_ADMIN_EMAILS_PRO(AUTOPURGE_ADMIN_DEL_MAILS_SUBJECT, "admin_autopurge_del_mails", $DELETED, "");
+               }
+                else
+               {
+                       $msg = LOAD_EMAIL_TEMPLATE("admin_autopurge_del_mails", $DELETED, "");
+                       SEND_ADMIN_EMAILS(AUTOPURGE_ADMIN_DEL_MAILS_SUBJECT, $msg);
+               }
+       }
+}
+
+if (EXT_IS_ACTIVE("rallye"))
+{
+       // Check expired rallyes (hard-coded 3 days limit for displaying expired rallyes!)
+       require_once(PATH."inc/libs/rallye_functions.php");
+       RALLYE_DELETE_EXPIRED_RALLYES();
+}
+//
+if (EXT_IS_ACTIVE("bonus"))
+{
+       // Check for expired turbo bonus lines
+       require_once(PATH."inc/libs/bonus_functions.php");
+       BONUS_PURGE_EXPIRED_TURBO_BONUS();
+}
+//
+?>
index 8a73f23807a695ba0ff55eff0a54e669ac3bfed4..97a49d396e1bb6536232dba013bb55732ebc1a58 100644 (file)
-<?php\r
-/************************************************************************\r
- * MXChange v0.2.1                                    Start: 08/25/2003 *\r
- * ===============                              Last change: 04/16/2004 *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * File              : config.php                                       *\r
- * -------------------------------------------------------------------- *\r
- * Short description : Your configuration data (MySQL)                  *\r
- * -------------------------------------------------------------------- *\r
- * Kurzbeschreibung  : Ihre Konfigurationsdaten (MySQL)                 *\r
- * -------------------------------------------------------------------- *\r
- *                                                                      *\r
- * -------------------------------------------------------------------- *\r
- * Copyright (c) 2003 - 2008 by Roland Haeder                           *\r
- * For more information visit: http://www.mxchange.org                  *\r
- *                                                                      *\r
- * This program is free software; you can redistribute it and/or modify *\r
- * it under the terms of the GNU General Public License as published by *\r
- * the Free Software Foundation; either version 2 of the License, or    *\r
- * (at your option) any later version.                                  *\r
- *                                                                      *\r
- * This program is distributed in the hope that it will be useful,      *\r
- * but WITHOUT ANY WARRANTY; without even the implied warranty of       *\r
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        *\r
- * GNU General Public License for more details.                         *\r
- *                                                                      *\r
- * You should have received a copy of the GNU General Public License    *\r
- * along with this program; if not, write to the Free Software          *\r
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,               *\r
- * MA  02110-1301  USA                                                  *\r
- ************************************************************************/\r
-\r
-// Some security stuff...\r
-if (!defined('__SECURITY'))\r
-{\r
-       $INC = substr(dirname(__FILE__), 0, strpos(dirname(__FILE__), "/inc") + 4) . "/security.php";\r
-       require($INC);\r
-}\r
-\r
-/************************************************************************\r
- *      PLEASE DO NOT EDIT THE COMMENTS! install.php NEEDS THEM!        *\r
- ************************************************************************/\r
-\r
-if (function_exists('date_default_timezone_set')) {\r
-       // CFG: TIME-ZONE\r
-       @date_default_timezone_set("Europe/Berlin");\r
-}\r
-\r
-// Most of these constants are old and deprecated. We don't use them either.\r
-// You can still feel free to use them in your templates / scripts if you like :-)\r
-define('VERSION', "v0.2.1");\r
-define('AUTHOR' , "Roland H&auml;der");\r
-define('TITLE', "MXChange - Mail Exchange");\r
-define('COPY', "&copy; 2003 - 2008, by <A href=\"http://www.mxchange.org\" target=\"_blank\" rel=\"external\" title=\"{!TITLE!} {!VERSION!}\">Roland H&auml;der</A>");\r
-\r
-// CFG: ERROR_REPORTING\r
-@error_reporting(0);\r
-\r
-// CFG: REGISTER-GLOBALS\r
-@import_request_variables('');\r
-\r
-// CFG: SITE-KEY\r
-define('SITE_KEY', "gg42ny8-4yng23498-mf423igum-mtu248utn42-mf4839gun43");\r
-\r
-// CFG: DATE-KEY\r
-define('DATE_KEY', date("d-m-Y (l-F-T)", time()));\r
-\r
-// CFG: DEFAULT-LANGUAGE\r
-define('DEFAULT_LANG', "de");\r
-\r
-// CFG: NULLPASS-WARNING\r
-define('warn_no_pass', true);\r
-\r
-// CFG: WRITE-FOOTER\r
-define('WRITE_FOOTER', true);\r
-\r
-// CFG: OUTPUT-MODE\r
-define('OUTPUT_MODE', "render");\r
-\r
-// CFG: MAIN_TITLE\r
-define('MAIN_TITLE', "Your mail-exchanger title");\r
-\r
-// CFG: SLOGAN\r
-define('SLOGAN', "Your cool slogan here");\r
-\r
-// Auto-detection...\r
-$URL = "http://".getenv('SERVER_NAME').dirname($_SERVER['PHP_SELF']);\r
-while (substr($URL, -1, 1) == "/") { $URL = substr($URL, 0, -1); }\r
-$PATH = substr(dirname(__FILE__), 0, -3);\r
-\r
-// CFG: HOST-URL (without trailing '/' !)\r
-define('URL', $URL);\r
-\r
-// CFG: SERVER-PATH\r
-define('PATH', $PATH);\r
-\r
-// CFG: WEBMASTER\r
-define('WEBMASTER', "you@some-hoster.tld.invalid");\r
-\r
-// CFG: INSTALLED\r
-define('mxchange_installed', false);\r
-\r
-// CFG: ADMIN-SETUP\r
-define('admin_registered', false);\r
-\r
-// CFG: FRAMESET\r
-define('frameset_active', false);\r
-\r
-// CFG: DEBUG-MODE (if enabled all mails will be *displayed* and *not* send!)\r
-define('DEBUG_MODE', false);\r
-\r
-// When we are not installing\r
-if (!defined('mxchange_installing')) define('mxchange_installing', false);\r
-\r
-// Language stuff (default is german)\r
-require_once(PATH."inc/language.php");\r
-\r
-// We need general functions and database stuff here\r