code
stringlengths
1
2.01M
repo_name
stringlengths
3
62
path
stringlengths
1
267
language
stringclasses
231 values
license
stringclasses
13 values
size
int64
1
2.01M
using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; using System.Data; public partial class Site_ShoppingCart : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { // populate the control only on the initial page load if (!IsPostBack) { this.Form.Action = "Site/ShoppingCart.aspx"; PopulateControls(); } } // fill shopping cart controls with data private void PopulateControls() { // get the items in the shopping cart DataTable dt = ShoppingCartAccess.GetItems(); // if the shopping cart is empty... if (dt.Rows.Count == 0) { ReportLabel.Text = "លោកអ្នកមិនមានទំនិញក្នុងកន្ត្រកទេ!"; CartView.Visible = false; checkoutButton.Enabled = false; updateButton.Enabled = false; totalAmountLabel.Text = String.Format("{0:c}", 0); } else // if the shopping cart is not empty... { // populate the list with the shopping cart contents CartView.DataSource = dt; CartView.DataBind(); // setup control ReportLabel.Text = "លោកអ្នកមិនមានទំនិញក្នុងកន្ត្រកទេ!"; CartView.Visible = true; updateButton.Enabled = true; checkoutButton.Enabled = true; // display the total amount decimal amount = ShoppingCartAccess.GetTotalAmount(); totalAmountLabel.Text = String.Format("{0:c}", amount); } } // remove a product from the cart protected void grid_RowDeleting(object sender, GridViewDeleteEventArgs e) { // Index of the row being deleted int rowIndex = e.RowIndex; // The ID of the product being deleted string productId = CartView.DataKeys[rowIndex].Value.ToString(); // Remove the product from the shopping cart bool success = ShoppingCartAccess.RemoveItem(productId); // Display status statusLabel.Text = success ? "Product successfully removed!" : "There was an error removing the product! "; // Repopulate the control PopulateControls(); Response.Redirect(Request.RawUrl); } // update shopping cart product quantities protected void updateButton_Click(object sender, EventArgs e) { // Number of rows in the GridView int rowsCount = CartView.Rows.Count; // Will store a row of the GridView GridViewRow gridRow; // Will reference a quantity TextBox in the GridView TextBox quantityTextBox; // Variables to store product ID and quantity string productId; int quantity; // Was the update successful? bool success = true; // Go through the rows of the GridView for (int i = 0; i < rowsCount; i++) { // Get a row gridRow = CartView.Rows[i]; // The ID of the product being deleted productId = CartView.DataKeys[i].Value.ToString(); // Get the quantity TextBox in the Row quantityTextBox = (TextBox)gridRow.FindControl("editQuantity"); // Get the quantity, guarding against bogus values if (Int32.TryParse(quantityTextBox.Text, out quantity)) { // Update product quantity success = success && ShoppingCartAccess.UpdateItem(productId, quantity); } else { // if TryParse didn't succeed success = false; } // Display status message statusLabel.Text = success ? "Your shopping cart was successfully updated!" : "Some quantity updates failed! Please verify your cart!"; } // Repopulate the control PopulateControls(); } }
014-01-elegantfood
trunk/Site/ShoppingCart.aspx.cs
C#
mit
3,584
<%@ Page Title="" Language="C#" MasterPageFile="~/Site/ElegantFood.master" AutoEventWireup="true" CodeFile="ShoppingCart.aspx.cs" Inherits="Site_ShoppingCart" %> <asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server"> </asp:Content> <asp:Content ID="Content3" ContentPlaceHolderID="ProductHeading" runat="server"> <h2> ទំនិញដែលអ្នកបានទិញដាក់ក្នុងកន្ត្រក</h2> </asp:Content> <asp:Content ID="Content2" ContentPlaceHolderID="ContentElegantFood" runat="Server"> <div class="col-md-12"> <p> <asp:Label ID="ReportLabel" runat="server" /> <asp:Label ID="statusLabel" runat="server" /> </p> <asp:GridView ID="CartView" runat="server" AutoGenerateColumns="False" DataKeyNames="ProductID" OnRowDeleting="grid_RowDeleting" GridLines="None" CssClass="table table-hover table-striped"> <Columns> <asp:BoundField DataField="Name" HeaderText="ឈ្មោះម្ហូប" ReadOnly="True" SortExpression="Name"> <ControlStyle Width="100%" /> </asp:BoundField> <asp:BoundField DataField="Price" DataFormatString="{0:c}" HeaderText="តម្លៃ" ReadOnly="True" SortExpression="Price" /> <asp:TemplateField HeaderText="បរិមាណ"> <ItemTemplate> <asp:TextBox ID="editQuantity" runat="server" CssClass="" Width="24px" MaxLength="2" Text='<%#Eval("Quantity")%>' /> </ItemTemplate> </asp:TemplateField> <asp:BoundField DataField="Subtotal" DataFormatString="{0:c}" HeaderText="សរុប" ReadOnly="True" SortExpression="Subtotal" /> <asp:ButtonField ButtonType="Button" CommandName="Delete" Text="លុប" ControlStyle-CssClass="btn btn-danger btn-xs"> </asp:ButtonField> </Columns> </asp:GridView> <p align="right"> <span>សរុបការចំណាយ: </span> <asp:Label ID="totalAmountLabel" runat="server" Text="Label" /> </p> <p class="pull-right"> <asp:HyperLink ID="gobackLink" CssClass="btn btn-primary btn-sm" runat="server" NavigateUrl="~/Default.aspx" Text="ត្រឡប់ទៅរើសទំនិញវិញ" /> <asp:Button ID="updateButton" runat="server" Text="កែប្រែបរិមាណ" OnClick="updateButton_Click" CssClass="btn btn-success btn-sm" /> <asp:HyperLink ID="checkoutButton" CssClass="btn btn-warning btn-sm" NavigateUrl="Site/CustomerCheckout.aspx" runat="server" Text="ដំណើរការការបញ្ជាទិញ" /> </p> </div> </asp:Content>
014-01-elegantfood
trunk/Site/ShoppingCart.aspx
ASP.NET
mit
2,574
using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; using System.Data; public partial class Site_CustomerCheckout2 : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { this.Form.Action = "Site/CustomerCheckout2.aspx"; EF_CustomerProperty customer = new EF_CustomerProperty(); customerName.Text = Session["CustomerName"].ToString(); customerPhone.Text = Session["CustomerPhone"].ToString(); customerEmail.Text = Session["CustomerEmail"].ToString(); shippingAddress.Text = Session["ShippingAddress"].ToString(); cartView.DataSource = ShoppingCartAccess.GetItems(); cartView.DataBind(); decimal amount = ShoppingCartAccess.GetTotalAmount(); totalAmountLabel.Text = String.Format("{0:c}", amount); } } protected void nextCompleteCheckout_Click(object sender, EventArgs e) { // Get the total amount decimal amount = ShoppingCartAccess.GetTotalAmount(); // Get customer information EF_CustomerProperty customer = new EF_CustomerProperty(); customer.CustomerName = customerName.Text; customer.CustomerPhone = customerPhone.Text; customer.CustomerEmail = customerEmail.Text; customer.ShippingAddress = shippingAddress.Text; ​​​// Create email body DataTable dt = ShoppingCartAccess.GetItems(); string body = "<!DOCTYPE HTML><html lang=\"km\"><head><meta charset=\"UTF-8\"></head><body><table border=\"1\" cellpadding=\"5\" cellspacing=\"0\" style=\"border-collapse: collapse;\"><thead><tr><th align=\"left\">ល.រ</th><th align=\"left\">ឈ្មោះទំនិញ</th><th align=\"left\">តម្លៃរាយ</th><th align=\"left\">ចំនួន</th><th align=\"left\">សរុប</th></tr></thead><tbody>"; foreach(DataRow dr in dt.Rows) { string tt = dr["Name"].ToString(); body += "<tr>" + "<td>" + dr["Name"].ToString()+"</td>" + "<td>" + String.Format("{0:c}", dr["Price"]).ToString() +"</td>" + "<td>" + dr["Quantity"].ToString() +"</td>" + "<td>" + String.Format("{0:c}", dr["Subtotal"]).ToString() +"</td>" +"</tr>"; } body += "<tr><td colspan=\"3\" align=\"right\">សរុបរួម</td><td>" + String.Format("{0:c}", amount).ToString() +"</td></tr>"; body += "</tbody></table></body>"; // Create the order and store the order ID ShoppingCartAccess.CreateOrder(customer); if (ElegantFoodConfiguration.EnableSendInvoice) { string subject = "Elegant Food - Order invoice"; string to = customerEmail.Text; Utilities.SendMail(ElegantFoodConfiguration.MailFrom, to, subject, body); } Response.Redirect("CustomerCheckoutComplete.aspx"); } }
014-01-elegantfood
trunk/Site/CustomerCheckout2.aspx.cs
C#
mit
2,795
<%@ Page Title="" Language="C#" MasterPageFile="~/Site/ElegantFood.master" AutoEventWireup="true" CodeFile="CustomerCheckout2.aspx.cs" Inherits="Site_CustomerCheckout2" %> <asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server"> </asp:Content> <asp:Content ID="Content2" ContentPlaceHolderID="ImageBanner" Runat="Server"> </asp:Content> <asp:Content ID="Content3" ContentPlaceHolderID="ProductHeading" Runat="Server"> <h2> ដំណើរការបញ្ជាទិញ - ដំណាក់កាលទី២</h2> </asp:Content> <asp:Content ID="Content4" ContentPlaceHolderID="ContentElegantFood" Runat="Server"> <div class="col-md-12"> <div class="row"> <div class="col-md-5"> <div class="panel panel-default"> <div class="panel-heading"> <h3 class="panel-title">ព័ត៌មានអតិថិជន</h3> </div> <div class="panel-body"> <dl class="dl-horizontal ef-no-margin-bottom"> <dt>ឈ្មោះ</dt> <dd>: <asp:Label ID="customerName" runat="server" /></dd> <dt>លេខទូរស័ព្ទ</dt> <dd> : <asp:Label ID="customerPhone" runat="server" /></dd> <dt>អ៊ីម៉ែល</dt> <dd> : <asp:Label ID="customerEmail" runat="server" /></dd> <dt>អាស័យដ្ឋាន</dt> <dd> : <asp:Label ID="shippingAddress" runat="server" /></dd> </dl> </div> </div> </div> <div class="col-md-7"> <div class="panel panel-default"> <div class="panel-heading"> <h3 class="panel-title"> ព័ត៌មានទំនិញ</h3> </div> <div class="panel-body"> <asp:GridView ID="cartView" runat="server" GridLines="None" CssClass="table table-hover table-striped ef-no-margin-bottom" AutoGenerateColumns="false"> <Columns> <asp:BoundField DataField="Name" HeaderText="ឈ្មោះម្ហូប" SortExpression="Name" /> <asp:BoundField DataField="Price" DataFormatString="{0:c}" HeaderText="តម្លៃ" SortExpression="Price" /> <asp:BoundField DataField="Quantity" HeaderText="បរិមាណ" SortExpression="Quantity" /> <asp:BoundField DataField="Subtotal" HeaderText="សរុប" DataFormatString="{0:c}" SortExpression="Subtotal" /> </Columns> </asp:GridView> <hr /> <p class="help-block pull-right"> <span>សរុបការចំណាយ: </span> <asp:Label ID="totalAmountLabel" runat="server" Text="Label" /> </p> </div> </div> </div> </div> <hr /> <asp:HyperLink ID="gobackButton" runat="server" Text="ត្រឡប់ក្រោយ" NavigateUrl="Site/CustomerCheckout.aspx" CssClass="btn btn-danger btn-sm pull-left" /> <asp:Button ID="nextCompleteCheckout" runat="server" Text="បញ្ចប់ការបញ្ជាទិញ" OnClick="nextCompleteCheckout_Click" CssClass="btn btn-success btn-sm pull-right" /> </div> </asp:Content>
014-01-elegantfood
trunk/Site/CustomerCheckout2.aspx
ASP.NET
mit
3,068
using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; public partial class Site_CustomerCheckoutComplete : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { } }
014-01-elegantfood
trunk/Site/CustomerCheckoutComplete.aspx.cs
C#
mit
301
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
014-01-elegantfood
trunk/Site/index.html
HTML
mit
114
<%@ Page Title="" Language="C#" MasterPageFile="~/Site/ElegantFood.master" AutoEventWireup="true" CodeFile="CustomerCheckout.aspx.cs" Inherits="Site_CustomerCheckout" %> <asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server"> </asp:Content> <asp:Content ID="Content2" ContentPlaceHolderID="ImageBanner" runat="Server"> </asp:Content> <asp:Content ID="Content3" ContentPlaceHolderID="ProductHeading" runat="Server"> <h2> ដំណើរការបញ្ជាទិញ - ដំណាក់កាលទី១</h2> </asp:Content> <asp:Content ID="Content4" ContentPlaceHolderID="ContentElegantFood" runat="Server"> <div class="col-md-12"> <div class="row"> <div class="col-md-6"> <div class="panel panel-default"> <div class="panel-heading"> <h3 class="panel-title"> ព័ត៌មានអតិថិជន</h3> </div> <div class="panel-body"> <div class="form-group"> <asp:Label ID="CustomerNameLabel" runat="server" AssociatedControlID="CustomerName">ឈ្មោះ <span class="ef-required">*</span></asp:Label> <asp:RequiredFieldValidator ID="CustomerNameRequired" runat="server" ErrorMessage="ឈ្មោះត្រូវតែបញ្ចូល!" CssClass="ef-required" ControlToValidate="CustomerName" /> <asp:TextBox ID="CustomerName" runat="server" CssClass="form-control" /> </div> <div class="form-group"> <asp:Label ID="CustomerPhoneLabel" runat="server" AssociatedControlID="CustomerPhone">លេខទូរស័ព្ទ<span class="ef-required">*</span></asp:Label> <asp:RequiredFieldValidator ID="CustomerPhoneRequired" runat="server" ErrorMessage="លេខទូរាំ័ព្ទត្រូវតែបញ្ជូល!" CssClass="ef-required" ControlToValidate="CustomerPhone" /> <asp:TextBox ID="CustomerPhone" runat="server" CssClass="form-control" /> </div> <div class="form-group"> <asp:Label ID="CustomerEmailLabel" runat="server" AssociatedControlID="CustomerEmail">អ៊ីម៉ែល</asp:Label> <asp:TextBox ID="CustomerEmail" runat="server" CssClass="form-control" /> </div> </div> </div> </div> <div class="col-md-6"> <div class="panel panel-default"> <div class="panel-heading"> <h3 class="panel-title"> ទីតាំងទទួលទំនិញ</h3> </div> <div class="panel-body"> <div class="form-group"> <asp:TextBox ID="ShippingAddress" runat="server" CssClass="form-control" TextMode="MultiLine" Columns="25" Rows="5" /> <p class="help-block"> <asp:RequiredFieldValidator ID="ShippingAddressRequired" runat="server" ErrorMessage="ទីតាំងទទួលទំនិញត្រូវតែបំពេញ!" CssClass="ef-required" ControlToValidate="ShippingAddress" /> </p> </div> </div> </div> </div> </div> <hr /> <asp:HyperLink ID="gobackButton" runat="server" Text="ត្រឡប់ក្រោយ" NavigateUrl="Site/ShoppingCart.aspx" CssClass="btn btn-danger btn-sm pull-left" /> <asp:Button ID="nextCheckout2" runat="server" Text="បន្តទៅដំណាក់កាលទីពីរ" OnClick="nextCheckout2_Click" CssClass="btn btn-info btn-sm pull-right" /> </div> </asp:Content>
014-01-elegantfood
trunk/Site/CustomerCheckout.aspx
ASP.NET
mit
3,418
<%@ Page Title="" Language="C#" MasterPageFile="~/Site/ElegantFood.master" AutoEventWireup="true" CodeFile="ProductDetail.aspx.cs" Inherits="Site_Product_ProductDetail" %> <asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server"> </asp:Content> <asp:Content ID="Content3" ContentPlaceHolderID="ImageBanner" runat="server"> <img src="../App_Resources/Images/banner1.jpg" alt="Banner1" width="1140" /> </asp:Content> <asp:Content ID="Content4" ContentPlaceHolderID="ProductHeading" runat="server"> <h2> ព័ត៌មានលម្អិតពីម្ហូប </h2> </asp:Content> <asp:Content ID="Content2" ContentPlaceHolderID="ContentElegantFood" Runat="Server"> <asp:Repeater ID="productDetails" runat="server"> <ItemTemplate> <div class="col-md-6 product-detail"> <div class="thumbnail"> <img src="Uploads/<%# Eval("Image") %>" alt="" width="399" /> </div> </div> <div class="col-md-6"> <div class="caption"> <h3 class="panel-title"> <%# Eval("Name") %> </h3> <br /> <dl class="dl-horizontal"> <dt>ការពិព័ណ៌នា</dt> <dd><%# Eval("Description") %></dd> <dt>តម្លៃ</dt> <dd> <%# Eval("Price", "{0:c}") %></dd> </dl> <p class="help-block"> <asp:LinkButton ID="AddToCartButton" runat="server" CssClass="btn btn-info btn-xs pull-left" OnClick="AddToCartButton_Click">ដាក់ចូលកន្ត្រក</asp:LinkButton> <asp:Label ID="DisplayProductID" runat="server" /> </p> </div> </div> </ItemTemplate> </asp:Repeater> </asp:Content>
014-01-elegantfood
trunk/Site/ProductDetail.aspx
ASP.NET
mit
1,661
using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; public partial class Site_CustomerCheckout : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { this.Form.Action = "Site/CustomerCheckout.aspx"; } protected void nextCheckout2_Click(object sender, EventArgs e) { Session["CustomerName"] = CustomerName.Text.Trim(); Session["CustomerEmail"] = CustomerEmail.Text.Trim(); Session["CustomerPhone"] = CustomerPhone.Text.Trim(); Session["ShippingAddress"] = ShippingAddress.Text.Trim(); Response.Redirect("CustomerCheckout2.aspx"); } }
014-01-elegantfood
trunk/Site/CustomerCheckout.aspx.cs
C#
mit
696
using System; using System.Collections.Generic; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; public partial class ElegantFood : System.Web.UI.MasterPage { protected void Page_Load(object sender, EventArgs e) { labelViewCart.Visible = false; Int32 item = ShoppingCartAccess.GetTotalItem(); if (item > 0) labelViewCart.Visible = true; displayTotalAmount.Text = item.ToString(); decimal amount = ShoppingCartAccess.GetTotalAmount(); displayTotalPrice.Text = String.Format("{0:c}", amount); } }
014-01-elegantfood
trunk/Site/ElegantFood.master.cs
C#
mit
568
using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; public partial class Site_Product_ProductDetail : System.Web.UI.Page { protected void Page_Load(object sender, EventArgs e) { this.Form.Action = "Site/ProductDetail.aspx"; if (!IsPostBack) { Session["ProductID"] = Request.QueryString["ProductID"]; productDetails.DataSource = EF_Product.GetProductById(Session["ProductID"].ToString()); productDetails.DataBind(); } } protected void AddToCartButton_Click(object sender, EventArgs e) { // Retrieve ProductID from the query string string productId = Session["ProductID"].ToString(); // Retrieve the selected product options ShoppingCartAccess.AddItem(productId); Response.Redirect(Request.RawUrl + "?ProductID=" + productId); } }
014-01-elegantfood
trunk/Site/ProductDetail.aspx.cs
C#
mit
890
using System; using System.Data; using System.Data.Common; /// <summary> /// Wraps department details data /// </summary> public struct DepartmentDetails { public string Name; public string Description; } /// <summary> /// Wraps category details data /// </summary> public struct CategoryDetails { public int DepartmentId; public string Name; public string Description; } /// <summary> /// Wraps product details data /// </summary> public struct ProductDetails { public int ProductID; public int UserID; public int CategoryID; public string Name; public string Description; public decimal Price; public string Thumbnail; public string Image; public DateTime CreateDate; public DateTime ModifyDate; public bool Status; } /// <summary> /// Product catalog business tier component /// </summary> public static class EF_CatalogAccess { static EF_CatalogAccess() { // // TODO: Add constructor logic here // } // Get category details public static CategoryDetails GetCategoryDetails(string categoryId) { // get a configured DbCommand object DbCommand comm = GenericDataAccess.CreateCommand(); // set the stored procedure name comm.CommandText = "EF_CatalogGetCategoryDetails"; // create a new parameter DbParameter param = comm.CreateParameter(); param.ParameterName = "@CategoryID"; param.Value = categoryId; param.DbType = DbType.Int32; comm.Parameters.Add(param); // execute the stored procedure DataTable table = GenericDataAccess.ExecuteSelectCommand(comm); // wrap retrieved data into a CategoryDetails object CategoryDetails details = new CategoryDetails(); if (table.Rows.Count > 0) { //details.DepartmentId = Int32.Parse(table.Rows[0]["DepartmentID"].ToString()); details.Name = table.Rows[0]["Name"].ToString(); details.Description = table.Rows[0]["Description"].ToString(); } // return department details return details; } // Get product details public static ProductDetails GetProductDetails(string productId) { // get a configured DbCommand object DbCommand comm = GenericDataAccess.CreateCommand(); // set the stored procedure name comm.CommandText = "EF_CatalogGetProductDetails"; // create a new parameter DbParameter param = comm.CreateParameter(); param.ParameterName = "@ProductID"; param.Value = productId; param.DbType = DbType.Int32; comm.Parameters.Add(param); // execute the stored procedure DataTable table = GenericDataAccess.ExecuteSelectCommand(comm); // wrap retrieved data into a ProductDetails object ProductDetails details = new ProductDetails(); if (table.Rows.Count > 0) { // get the first table row DataRow dr = table.Rows[0]; // get product details details.ProductID = int.Parse(productId); details.Name = dr["Name"].ToString(); details.Description = dr["Description"].ToString(); details.Price = Decimal.Parse(dr["Price"].ToString()); details.Thumbnail = dr["Thumbnail"].ToString(); details.Image = dr["Image"].ToString(); //details.CreateDate = DateTime.Parse(dr["CreateDate"].ToString()); //details.ModifyDate = DateTime.Parse(dr["ModifyDate"].ToString()); details.Status = bool.Parse(dr["Status"].ToString()); } // return department details return details; } // retrieve the list of products in a category public static DataTable GetProductsInCategory (string categoryId, string pageNumber, out int howManyPages) { // get a configured DbCommand object DbCommand comm = GenericDataAccess.CreateCommand(); // set the stored procedure name comm.CommandText = "EF_CatalogGetProductsInCategory"; // create a new parameter DbParameter param = comm.CreateParameter(); param.ParameterName = "@CategoryID"; param.Value = categoryId; param.DbType = DbType.Int32; comm.Parameters.Add(param); // create a new parameter param = comm.CreateParameter(); param.ParameterName = "@DescriptionLength"; param.Value = ElegantFoodConfiguration.ProductFrontDescriptionLength; param.DbType = DbType.Int32; comm.Parameters.Add(param); // create a new parameter param = comm.CreateParameter(); param.ParameterName = "@PageNumber"; param.Value = pageNumber; param.DbType = DbType.Int32; comm.Parameters.Add(param); // create a new parameter param = comm.CreateParameter(); param.ParameterName = "@ProductsPerPage"; param.Value = ElegantFoodConfiguration.ProductsFrontPerPage; param.DbType = DbType.Int32; comm.Parameters.Add(param); // create a new parameter param = comm.CreateParameter(); param.ParameterName = "@HowManyProducts"; param.Direction = ParameterDirection.Output; param.DbType = DbType.Int32; comm.Parameters.Add(param); // execute the stored procedure and save the results in a DataTable DataTable table = GenericDataAccess.ExecuteSelectCommand(comm); // calculate how many pages of products and set the out parameter int howManyProducts = Int32.Parse(comm.Parameters["@HowManyProducts"].Value.ToString()); howManyPages = (int)Math.Ceiling((double)howManyProducts / (double)ElegantFoodConfiguration.ProductsFrontPerPage); // return the page of products return table; } }
014-01-elegantfood
trunk/App_Code/EF_CatalogAccess.cs
C#
mit
5,311
using System; using System.Data; using System.Data.Common; using System.Reflection; /// <summary> /// Populate all action with Category /// </summary> public static class EF_Category { static EF_Category() { } // Create new category public static void CreateCategory(EF_CategoryProperty category) { DbCommand cmd = GenericDataAccess.CreateCommand(); cmd.CommandText = "EF_CreateCategory"; DbParameter CateParam = cmd.CreateParameter(); CateParam.ParameterName = "@UserID"; CateParam.Value = category.UserID; cmd.Parameters.Add(CateParam); CateParam = cmd.CreateParameter(); CateParam.ParameterName = "@Name"; CateParam.Value = category.Name; cmd.Parameters.Add(CateParam); CateParam = cmd.CreateParameter(); CateParam.ParameterName = "@Description"; CateParam.Value = category.Description; cmd.Parameters.Add(CateParam); CateParam = cmd.CreateParameter(); CateParam.ParameterName = "@Status"; CateParam.Value = category.Status; cmd.Parameters.Add(CateParam); GenericDataAccess.ExecuteCommand(cmd); } // Get all categories public static DataTable GetCategory (int DescriptionLength = 25) { DbCommand cmd = GenericDataAccess.CreateCommand(); cmd.CommandText = "EF_GetCategory"; DbParameter CateParam = cmd.CreateParameter(); CateParam.ParameterName = "@DescriptionLength"; CateParam.Value = DescriptionLength; cmd.Parameters.Add(CateParam); return GenericDataAccess.ExecuteSelectCommand(cmd); } ​​// Update category public static bool UpdateCategory(EF_CategoryProperty category) { DbCommand cmd = GenericDataAccess.CreateCommand(); cmd.CommandText = "EF_UpdateCategoryById"; DbParameter CateParam = cmd.CreateParameter(); CateParam.ParameterName = "@CategoryID"; CateParam.Value = category.CategoryID; cmd.Parameters.Add(CateParam); CateParam = cmd.CreateParameter(); CateParam.ParameterName = "@Name"; CateParam.Value = category.Name; cmd.Parameters.Add(CateParam); CateParam = cmd.CreateParameter(); CateParam.ParameterName = "@Description"; CateParam.Value = category.Description; cmd.Parameters.Add(CateParam); CateParam = cmd.CreateParameter(); CateParam.ParameterName = "@Status"; CateParam.Value = category.Status; cmd.Parameters.Add(CateParam); if (GenericDataAccess.ExecuteCommand(cmd)) { return true; } return false; } // Delete category by name public static bool DeleteCategory(string categoryId) { DbCommand cmd = GenericDataAccess.CreateCommand(); cmd.CommandText = "EF_DeleteCategory"; DbParameter CateParam = cmd.CreateParameter(); CateParam.ParameterName = "@CategoryID"; CateParam.Value = categoryId; CateParam.DbType = DbType.Int32; cmd.Parameters.Add(CateParam); if (GenericDataAccess.ExecuteCommand(cmd)) { return true; } return false; } }
014-01-elegantfood
trunk/App_Code/EF_Category.cs
C#
mit
2,932
using System; using System.Collections.Generic; using System.Net; using System.Net.Mail; using System.Security; using System.Security.Cryptography; using System.Text; using System.IO; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; using System.Web.Security; /// <summary> /// Contains miscellaneous functionality /// </summary> public static class Utilities { static Utilities() { // // TODO: Add constructor logic here // } /// <summary> /// Send Email /// </summary> /// <param name="from">Sender email address</param> /// <param name="to">Recipient email address</param> /// <param name="subject">Subject of email</param> /// <param name="body">Email message</param> public static void SendMail(string from, string to, string subject, string body) { // Configuration mail client SmtpClient mailClient = new SmtpClient(ElegantFoodConfiguration.MailServer, ElegantFoodConfiguration.MailServerPort); // Enable SSL mailClient.EnableSsl = true; // Set credentials (for SMTP servers that require authentication) mailClient.Credentials = new NetworkCredential(ElegantFoodConfiguration.MailUser, ElegantFoodConfiguration.MailPassword); // Create the mail message MailMessage message = new MailMessage(from, to, subject, body); // is body html format? message.IsBodyHtml = true; // Send mail mailClient.Send(message); } public static void LogError(Exception error) { // Get the current date and time string dateTime = DateTime.Now.ToLongDateString() + ", at " + DateTime.Now.ToShortDateString(); // Stores the error message string errorMessage = "Exception generated on " + dateTime; // Obtain the page that generated error System.Web.HttpContext context = System.Web.HttpContext.Current; // Build the error message errorMessage += "\n\n Page location: " + context.Request.RawUrl; errorMessage += "\n\n Message: " + error.Message; errorMessage += "\n\n Source: " + error.Source; errorMessage += "\n\n Method: " + error.TargetSite; errorMessage += "\n\n Stack Trace: \n\n" + error.StackTrace; // Send error email in case the option is activated in web.config if (ElegantFoodConfiguration.EnableErrorLogMail) { string from = ElegantFoodConfiguration.MailFrom; string to = ElegantFoodConfiguration.ErrorLogMail; string subject = "ElegantFood Error Report"; string body = errorMessage; SendMail(from, to, subject, body); } } /// <summary> /// Security encrypt string to readable BitConverter /// </summary> /// <param name="password">String to be encrypted</param> /// <returns>Readable BitConverter</returns> public static string Encrypted(string str) { Byte[] OriginalByte; Byte[] EncodeByte; MD5 md5; // Instantiate MD5CrytoServiceProvider, get bytes for original password and compute hash (encoded password) md5 = new MD5CryptoServiceProvider(); OriginalByte = ASCIIEncoding.Default.GetBytes(str); EncodeByte = md5.ComputeHash(OriginalByte); // Convert encoded byted back to a readable string return BitConverter.ToString(EncodeByte); } ​​​​// Get active login user ID public static string UserLoginID() { return Membership.GetUser().ProviderUserKey.ToString(); } }
014-01-elegantfood
trunk/App_Code/Utilities.cs
C#
mit
3,343
using System; using System.Collections.Generic; using System.Linq; using System.Web; /// <summary> /// Link factory class /// </summary> public class Link { // Builds an absolute URL private static string BuildAbsolute(string relativeUri) { // get current uri Uri uri = HttpContext.Current.Request.Url; // build absolute path string app = HttpContext.Current.Request.ApplicationPath; if (!app.EndsWith("/")) app += "/"; relativeUri = relativeUri.TrimStart('/'); // return the absolute path return HttpUtility.UrlPathEncode(String.Format("http://{0}:{1}{2}{3}", uri.Host, uri.Port, app, relativeUri)); } // Generate a page URL public static string ToPage(string page, string url) { return BuildAbsolute(String.Format(url + "?Page={0}", page)); } // Generate a product URL public static string ToProduct(string productID) { return BuildAbsolute(String.Format("Site/ProductDetail.aspx?ProductID={0}", productID)); } // Generate a shopping cart URL public static string ToShoppingCart(string productID) { return BuildAbsolute(String.Format("Site/ShoppingCart.aspx?ProductID={0}", productID)); } // Generate a category URL public static string ToCategory(string categoryID) { return BuildAbsolute(String.Format("Default.aspx?CategoryID={0}", categoryID)); } }
014-01-elegantfood
trunk/App_Code/Link.cs
C#
mit
1,352
using System; /// <summary> /// Class EF_CustomerProperty /// </summary> public class EF_CustomerProperty { public EF_CustomerProperty() { // // TODO: Add constructor logic here // } public string CustomerName { get; set; } public string CustomerPhone { get; set; } public string CustomerEmail { get; set; } public string ShippingAddress { get; set; } }
014-01-elegantfood
trunk/App_Code/EF_CustomerProperty.cs
C#
mit
437
using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Data; using System.Data.Common; /// <summary> /// Wraps order data /// </summary> public struct OrderInfo { public int OrderID; public decimal TotalAmount; public string OrderDate; public string DateShipped; public bool Verified; public bool Completed; public bool Canceled; public string Comments; public string CustomerName; public string CustomerPhone; public string ShippingAddress; public string CustomerEmail; } /// <summary> /// Summary description for EF_OrderAccess /// </summary> public class EF_OrderAccess { public EF_OrderAccess() { // // TODO: Add constructor logic here // } public static DataTable GetOrder() { DbCommand cmd = GenericDataAccess.CreateCommand(); cmd.CommandText = "EF_GetOrder"; return GenericDataAccess.ExecuteSelectCommand(cmd); } // Retrieve order information public static OrderInfo GetInfo(string orderID) { // get a configured DbCommand object DbCommand comm = GenericDataAccess.CreateCommand(); // set the stored procedure name comm.CommandText = "EF_OrderGetInfo"; // create a new parameter DbParameter param = comm.CreateParameter(); param.ParameterName = "@OrderID"; param.Value = orderID; param.DbType = DbType.Int32; comm.Parameters.Add(param); // obtain the results DataTable table = GenericDataAccess.ExecuteSelectCommand(comm); DataRow orderRow = table.Rows[0]; // save the results into an OrderInfo object OrderInfo orderInfo; orderInfo.OrderID = Int32.Parse(orderRow["OrderID"].ToString()); orderInfo.TotalAmount = Decimal.Parse(orderRow["TotalAmount"].ToString()); orderInfo.OrderDate = orderRow["OrderDate"].ToString(); orderInfo.DateShipped = orderRow["DateShipped"].ToString(); orderInfo.Verified = bool.Parse(orderRow["Verified"].ToString()); orderInfo.Completed = bool.Parse(orderRow["Completed"].ToString()); orderInfo.Canceled = bool.Parse(orderRow["Canceled"].ToString()); orderInfo.Comments = orderRow["Comments"].ToString(); orderInfo.CustomerName = orderRow["CustomerName"].ToString(); orderInfo.ShippingAddress = orderRow["ShippingAddress"].ToString(); orderInfo.CustomerPhone = orderRow["CustomerPhone"].ToString(); orderInfo.CustomerEmail = orderRow["CustomerEmail"].ToString(); // return the OrderInfo object return orderInfo; } // Retrieve the order details (the products that are part of that order) public static DataTable GetDetails(string orderID) { // get a configured DbCommand object DbCommand comm = GenericDataAccess.CreateCommand(); // set the stored procedure name comm.CommandText = "EF_OrderGetDetails"; // create a new parameter DbParameter param = comm.CreateParameter(); param.ParameterName = "@OrderID"; param.Value = orderID; param.DbType = DbType.Int32; comm.Parameters.Add(param); // return the results DataTable table = GenericDataAccess.ExecuteSelectCommand(comm); return table; } // Update an order public static void Update(OrderInfo orderInfo) { // get a configured DbCommand object DbCommand comm = GenericDataAccess.CreateCommand(); // set the stored procedure name comm.CommandText = "EF_OrderUpdate"; // create a new parameter DbParameter param = comm.CreateParameter(); param.ParameterName = "@OrderID"; param.Value = orderInfo.OrderID; param.DbType = DbType.Int32; comm.Parameters.Add(param); // create a new parameter param = comm.CreateParameter(); param.ParameterName = "@DateCreated"; param.Value = orderInfo.OrderDate; param.DbType = DbType.DateTime; comm.Parameters.Add(param); // The DateShipped parameter is sent only if data is available if (orderInfo.DateShipped.Trim() != "") { param = comm.CreateParameter(); param.ParameterName = "@DateShipped"; param.Value = orderInfo.DateShipped; param.DbType = DbType.DateTime; comm.Parameters.Add(param); } // create a new parameter param = comm.CreateParameter(); param.ParameterName = "@Verified"; param.Value = orderInfo.Verified; param.DbType = DbType.Byte; comm.Parameters.Add(param); // create a new parameter param = comm.CreateParameter(); param.ParameterName = "@Completed"; param.Value = orderInfo.Completed; param.DbType = DbType.Byte; comm.Parameters.Add(param); // create a new parameter param = comm.CreateParameter(); param.ParameterName = "@Canceled"; param.Value = orderInfo.Canceled; param.DbType = DbType.Byte; comm.Parameters.Add(param); // create a new parameter param = comm.CreateParameter(); param.ParameterName = "@Comments"; param.Value = orderInfo.Comments; param.DbType = DbType.String; comm.Parameters.Add(param); // create a new parameter param = comm.CreateParameter(); param.ParameterName = "@CustomerName"; param.Value = orderInfo.CustomerName; param.DbType = DbType.String; comm.Parameters.Add(param); // create a new parameter param = comm.CreateParameter(); param.ParameterName = "@ShippingAddress"; param.Value = orderInfo.ShippingAddress; param.DbType = DbType.String; comm.Parameters.Add(param); // create a new parameter param = comm.CreateParameter(); param.ParameterName = "@CustomerEmail"; param.Value = orderInfo.CustomerEmail; param.DbType = DbType.String; comm.Parameters.Add(param); // return the results GenericDataAccess.ExecuteNonQuery(comm); } // Mark an order as verified public static void MarkVerified(string orderId) { // get a configured DbCommand object DbCommand comm = GenericDataAccess.CreateCommand(); // set the stored procedure name comm.CommandText = "EF_OrderMarkVerified"; // create a new parameter DbParameter param = comm.CreateParameter(); param.ParameterName = "@OrderID"; param.Value = orderId; param.DbType = DbType.Int32; comm.Parameters.Add(param); // return the results GenericDataAccess.ExecuteNonQuery(comm); } // Mark an order as completed public static void MarkCompleted(string orderId) { // get a configured DbCommand object DbCommand comm = GenericDataAccess.CreateCommand(); // set the stored procedure name comm.CommandText = "EF_OrderMarkCompleted"; // create a new parameter DbParameter param = comm.CreateParameter(); param.ParameterName = "@OrderID"; param.Value = orderId; param.DbType = DbType.Int32; comm.Parameters.Add(param); // return the results GenericDataAccess.ExecuteNonQuery(comm); } // Mark an order as canceled public static void MarkCanceled(string orderId) { // get a configured DbCommand object DbCommand comm = GenericDataAccess.CreateCommand(); // set the stored procedure name comm.CommandText = "EF_OrderMarkCanceled"; // create a new parameter DbParameter param = comm.CreateParameter(); param.ParameterName = "@OrderID"; param.Value = orderId; param.DbType = DbType.Int32; comm.Parameters.Add(param); // return the results GenericDataAccess.ExecuteNonQuery(comm); } }
014-01-elegantfood
trunk/App_Code/EF_OrderAccess.cs
C#
mit
7,212
using System; using System.Data; using System.Data.Common; using System.Data.SqlClient; /// <summary> /// Populate all action in product table /// </summary> public class EF_Product { // Add new product public static Int32 CreateProduct(EF_ProductProperty product) { DbCommand cmd = GenericDataAccess.CreateCommand(); cmd.CommandText = "EF_CreateProduct"; DbParameter ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@UserID"; ProductParam.Value = product.UserID; cmd.Parameters.Add(ProductParam); ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@Name"; ProductParam.Value = product.Name; cmd.Parameters.Add(ProductParam); ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@Description"; ProductParam.Value = product.Description; cmd.Parameters.Add(ProductParam); ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@Price"; ProductParam.Value = product.Price; cmd.Parameters.Add(ProductParam); ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@SpecialPrice"; ProductParam.Value = product.SpecialPrice; cmd.Parameters.Add(ProductParam); ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@Thumbnail"; ProductParam.Value = product.Thumbnail; cmd.Parameters.Add(ProductParam); ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@Image"; ProductParam.Value = product.Image; cmd.Parameters.Add(ProductParam); ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@HightLight"; ProductParam.Value = product.HightLight; cmd.Parameters.Add(ProductParam); ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@Promotion"; ProductParam.Value = product.Promotion; cmd.Parameters.Add(ProductParam); ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@Status"; ProductParam.Value = product.Status; cmd.Parameters.Add(ProductParam); ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@ProductID"; ProductParam.Direction = ParameterDirection.Output; ProductParam.DbType = DbType.Int32; cmd.Parameters.Add(ProductParam); GenericDataAccess.ExecuteCommand(cmd); return Int32.Parse(cmd.Parameters["@ProductID"].Value.ToString()); } // Check duplicated product name public static bool checkDuplicatedProductName(string ProductName) { DbCommand cmd = GenericDataAccess.CreateCommand(); cmd.CommandText = "EF_GetProductByName"; DbParameter ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@Name"; ProductParam.Value = ProductName; ProductParam.DbType = DbType.String; cmd.Parameters.Add(ProductParam); DataTable table = GenericDataAccess.ExecuteSelectCommand(cmd); if (table.Rows.Count > 0) return true; return false; } // Assign product to category public static void AssignProductToCategory(int ProductID, string[] CategoryIDs) { foreach (var CategoryID in CategoryIDs) { DbCommand cmd = GenericDataAccess.CreateCommand(); cmd.CommandText = "EF_ProductToCategory"; DbParameter ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@ProductID"; ProductParam.Value = ProductID; cmd.Parameters.Add(ProductParam); ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@CategoryID"; ProductParam.Value = CategoryID; ProductParam.DbType = DbType.Int32; cmd.Parameters.Add(ProductParam); GenericDataAccess.ExecuteCommand(cmd); } } // Select product public static DataTable GetProduct(string PageNumber, out int HowManyPages) { DbCommand cmd = GenericDataAccess.CreateCommand(); cmd.CommandText = "EF_GetProduct"; DbParameter ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@DescriptionLength"; ProductParam.Value = ElegantFoodConfiguration.ProductBackDescriptionLength; cmd.Parameters.Add(ProductParam); ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@PageNumber"; ProductParam.Value = PageNumber; ProductParam.DbType = DbType.Int32; cmd.Parameters.Add(ProductParam); ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@ProductsPerPage"; ProductParam.Value = ElegantFoodConfiguration.ProductsBackPerPage; cmd.Parameters.Add(ProductParam); ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@HowManyProducts"; ProductParam.Direction = ParameterDirection.Output; ProductParam.DbType = DbType.Int32; cmd.Parameters.Add(ProductParam); DataTable table = GenericDataAccess.ExecuteSelectCommand(cmd); int HowManyProducts = Int32.Parse(cmd.Parameters["@HowManyProducts"].Value.ToString()); HowManyPages = (int)Math.Ceiling((double)HowManyProducts / (double)ElegantFoodConfiguration.ProductsBackPerPage); return table; } // Get product by hightlight public static DataTable GetProductByHightLight() { DbCommand cmd = GenericDataAccess.CreateCommand(); cmd.CommandText = "EF_GetProductByHightLight"; return GenericDataAccess.ExecuteSelectCommand(cmd); } // Get product by promotion public static DataTable GetProductByPromotion() { DbCommand cmd = GenericDataAccess.CreateCommand(); cmd.CommandText = "EF_GetProductByPromotion"; return GenericDataAccess.ExecuteSelectCommand(cmd); } // Get product by id public static DataTable GetProductById(string id) { DbCommand cmd = GenericDataAccess.CreateCommand(); cmd.CommandText = "EF_GetProductByid"; DbParameter ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@ProductID"; ProductParam.Value = id; ProductParam.DbType = DbType.Int32; cmd.Parameters.Add(ProductParam); return GenericDataAccess.ExecuteSelectCommand(cmd); } // get product by category id public static DataTable GetProductByCategoryId(int id) { DbCommand cmd = GenericDataAccess.CreateCommand(); cmd.CommandText = "EF_GetProductByCategoryId"; DbParameter ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@CategoryID"; ProductParam.Value = id; ProductParam.DbType = DbType.Int32; cmd.Parameters.Add(ProductParam); return GenericDataAccess.ExecuteSelectCommand(cmd); } // Delete product by id public static bool DeleteProduct(int id) { DbCommand cmd = GenericDataAccess.CreateCommand(); cmd.CommandText = "EF_DeleteProductByID"; DbParameter ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@ProductID"; ProductParam.Value = id; ProductParam.DbType = DbType.Int32; cmd.Parameters.Add(ProductParam); if (GenericDataAccess.ExecuteCommand(cmd)) { return true; } return false; } public static bool UpdateProduct(EF_ProductProperty product) { DbCommand cmd = GenericDataAccess.CreateCommand(); cmd.CommandText = "EF_UpdateProductById"; DbParameter ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@ProductID"; ProductParam.Value = product.ProductID; ProductParam.DbType = DbType.Int32; cmd.Parameters.Add(ProductParam); ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@Name"; ProductParam.Value = product.Name; ProductParam.DbType = DbType.String; cmd.Parameters.Add(ProductParam); ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@Price"; ProductParam.Value = product.Price; ProductParam.DbType = DbType.Decimal; cmd.Parameters.Add(ProductParam); ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@Promotion"; ProductParam.Value = product.Promotion; ProductParam.DbType = DbType.Boolean; cmd.Parameters.Add(ProductParam); ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@HightLight"; ProductParam.Value = product.HightLight; ProductParam.DbType = DbType.Boolean; cmd.Parameters.Add(ProductParam); ProductParam = cmd.CreateParameter(); ProductParam.ParameterName = "@Status"; ProductParam.Value = product.Status; ProductParam.DbType = DbType.Boolean; cmd.Parameters.Add(ProductParam); if (GenericDataAccess.ExecuteCommand(cmd)) { return true; } return false; } }
014-01-elegantfood
trunk/App_Code/EF_Product.cs
C#
mit
8,406
using System; using System.Configuration; using System.Security; using System.Web.Security; /// <summary> /// Repository for BalloonShop configuration settings /// </summary> public static class ElegantFoodConfiguration { // Caches the connection string private static string dbConnectionString; // Caches the data provider name private static string dbProviderName; // Store the number of products frontend per page private readonly static int productsFrontPerPage; // Store the product frontend description length for product lists private readonly static int productFrontDescriptionLength; // Store the number of products backend per page private readonly static int productsBackPerPage; // Store the product backend description length for product lists private readonly static int productBackDescriptionLength; // Store the name of your shop private readonly static string siteName; static ElegantFoodConfiguration() { dbConnectionString = ConfigurationManager.ConnectionStrings["ElegantFoodConnectionString"].ConnectionString; dbProviderName = ConfigurationManager.ConnectionStrings["ElegantFoodConnectionString"].ProviderName; productsFrontPerPage = System.Int32.Parse(ConfigurationManager.AppSettings["ProductsFrontPerPage"]); productFrontDescriptionLength = System.Int32.Parse(ConfigurationManager.AppSettings["ProductFrontDescriptionLength"]); productsBackPerPage = System.Int32.Parse(ConfigurationManager.AppSettings["ProductsBackPerPage"]); productBackDescriptionLength = System.Int32.Parse(ConfigurationManager.AppSettings["ProductBackDescriptionLength"]); siteName = ConfigurationManager.AppSettings["SiteName"]; } // Returns the connection string for the BalloonShop database public static string DbConnectionString { get { return dbConnectionString; } } // Returns the data provider name public static string DbProviderName { get { return dbProviderName; } } // Returns the address of the mail server public static string MailServer { get { return ConfigurationManager.AppSettings["MailServer"]; } } // Returns the mail server port public static int MailServerPort { get { return Int32.Parse(ConfigurationManager.AppSettings["MailServerPort"]); } } // Returns the email username public static string MailUser { get { return ConfigurationManager.AppSettings["MailUser"]; } } // Returns the email password public static string MailPassword { get { return ConfigurationManager.AppSettings["MailPassword"]; } } // Returns the email password public static string MailFrom { get { return ConfigurationManager.AppSettings["MailFrom"]; } } // Send error log emails? public static bool EnableErrorLogMail { get { return bool.Parse(ConfigurationManager.AppSettings["EnableErrorLogMail"]); } } // Returns the email address where to send error reports public static string ErrorLogMail { get { return ConfigurationManager.AppSettings["ErrorLogMail"]; } } // Returns the maximum number of products frontend to be displayed on a page public static int ProductsFrontPerPage { get { return productsFrontPerPage; } } // Returns the length of product frontend descriptions in products lists public static int ProductFrontDescriptionLength { get { return productFrontDescriptionLength; } } // Returns the maximum number of products backend to be displayed on a page public static int ProductsBackPerPage { get { return productsBackPerPage; } } // Returns the length of product backend descriptions in products lists public static int ProductBackDescriptionLength { get { return productBackDescriptionLength; } } // Returns the length of product descriptions in products lists public static string SiteName { get { return siteName; } } // Returns current login user id public static Guid CurrentLoginUserID { get { return (Guid)Membership.GetUser().ProviderUserKey; } } // Returns the number of days for shopping cart expiration public static int CartPersistDays { get { return int.Parse(ConfigurationManager.AppSettings["CartPersistDays"]); } } // Send email invoice or not public static bool EnableSendInvoice { get { return bool.Parse(ConfigurationManager.AppSettings["EnableSendInvoice"]); } } }
014-01-elegantfood
trunk/App_Code/ElegantFoodConfiguration.cs
C#
mit
4,557
using System; using System.Data; using System.Data.Common; /// <summary> /// Summary description for EF_User /// </summary> public static class EF_User { private static DataTable table; static EF_User() { // // TODO: Add constructor logic here // } /// <summary> /// Create new user /// </summary> /// <param name="user">Collection of User properties</param> public static void InsertUser(EF_UserProperty user) { if (!checkUniqueUsername(user.Username)) { DbCommand cmd = GenericDataAccess.CreateCommand(); cmd.CommandText = "EF_InsertUser"; DbParameter UserParam = cmd.CreateParameter(); UserParam.ParameterName = "@RoleID"; UserParam.Value = user.RoleID; UserParam.DbType = DbType.Int32; cmd.Parameters.Add(UserParam); UserParam = cmd.CreateParameter(); UserParam.ParameterName = "@FirstName"; UserParam.Value = user.FirstName; UserParam.DbType = DbType.String; cmd.Parameters.Add(UserParam); UserParam = cmd.CreateParameter(); UserParam.ParameterName = "@LastName"; UserParam.Value = user.LastName; UserParam.DbType = DbType.String; cmd.Parameters.Add(UserParam); UserParam = cmd.CreateParameter(); UserParam.ParameterName = "@Username"; UserParam.Value = user.Username; UserParam.DbType = DbType.String; cmd.Parameters.Add(UserParam); UserParam = cmd.CreateParameter(); UserParam.ParameterName = "@Password"; UserParam.Value = user.Password; UserParam.DbType = DbType.String; cmd.Parameters.Add(UserParam); GenericDataAccess.ExecuteCommand(cmd); } else { // Email is already existed! } } public static DataTable SelectUser(Int32 id = 0) { DbCommand cmd = GenericDataAccess.CreateCommand(); cmd.CommandText = "EF_SelectUser"; DbParameter UserParam = cmd.CreateParameter(); UserParam.ParameterName = "@UserID"; UserParam.Value = id; UserParam.DbType = DbType.Int32; cmd.Parameters.Add(UserParam); table = new DataTable(); table = GenericDataAccess.ExecuteSelectCommand(cmd); return table; } /// <summary> /// Check whether the email is already existed or not /// </summary> /// <param name="email">New user email</param> /// <returns>Boolean</returns> public static bool checkUniqueUsername(string username) { DbCommand cmd = GenericDataAccess.CreateCommand(); cmd.CommandText = "EF_CheckUsernameUser"; DbParameter UserParam = cmd.CreateParameter(); UserParam.ParameterName = "@Username"; UserParam.Value = username; UserParam.DbType = DbType.String; cmd.Parameters.Add(UserParam); table = new DataTable(); table = GenericDataAccess.ExecuteSelectCommand(cmd); if (table.Rows.Count > 0) return true; return false; } }
014-01-elegantfood
trunk/App_Code/EF_User.cs
C#
mit
2,813
using System; /// <summary> /// Class EF_UserProperty holds all the column name of user table /// </summary> public class EF_UserProperty { public EF_UserProperty() { // // TODO: Add constructor logic here // } public Int32 UserID { get; set; } public Int32 RoleID { get; set; } public string FirstName { get; set; } public string LastName { get; set; } public string Username { get; set; } public string Password { get; set; } public DateTime CreateDate { get; set; } public DateTime ModifyDate { get; set; } public bool Status { get; set; } public string Email { get; set; } }
014-01-elegantfood
trunk/App_Code/EF_UserProperty.cs
C#
mit
763
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
014-01-elegantfood
trunk/App_Code/index.html
HTML
mit
114
using System; using System.Data; using System.Data.Common; /// <summary> /// Contains generic data access functionality to be accessed from the business tier /// </summary> public static class GenericDataAccess { static GenericDataAccess() { // // TODO: Add constructor logic here // } /// <summary> /// Execute a command and returns the results as a DataTable object /// </summary> /// <param name="cmd">SQL Command</param> /// <returns>DataTable Object</returns> public static DataTable ExecuteSelectCommand(DbCommand cmd) { DataTable table; try { cmd.Connection.Open(); DbDataReader reader = cmd.ExecuteReader(); table = new DataTable(); table.Load(reader); reader.Close(); } catch (Exception error) { //Utilities.LogError(error); throw error; } finally { cmd.Connection.Close(); } return table; } /// <summary> /// Execute a insert command /// </summary> /// <param name="cmd">SQL Command</param> public static bool ExecuteCommand(DbCommand cmd) { try { cmd.Connection.Open(); if (cmd.ExecuteNonQuery() == 1) { return true; } return false; } catch (Exception error) { Utilities.LogError(error); throw; } finally { cmd.Connection.Close(); } } /// <summary> /// Create and prepare a new DbCommand object on a new connection /// </summary> /// <returns>SQL Command object as store procedure only</returns> public static DbCommand CreateCommand() { // Obtain the database provider name string dataProviderName = ElegantFoodConfiguration.DbProviderName; // Obtain the database connection string string connectionString = ElegantFoodConfiguration.DbConnectionString; // Create new data provider factory DbProviderFactory factory = DbProviderFactories.GetFactory(dataProviderName); // Obtain a database-specific connection object DbConnection conn = factory.CreateConnection(); // Set the connection string conn.ConnectionString = connectionString; // Create database-specific command object DbCommand cmd = conn.CreateCommand(); // Set the command type for store procedure cmd.CommandType = CommandType.StoredProcedure; // Return command return cmd; } // execute an update, delete, or insert command // and return the number of affected rows public static int ExecuteNonQuery(DbCommand command) { // The number of affected rows int affectedRows = -1; // Execute the command making sure the connection gets closed in the end try { // Open the connection of the command command.Connection.Open(); // Execute the command and get the number of affected rows affectedRows = command.ExecuteNonQuery(); } catch (Exception ex) { // Log eventual errors and rethrow them Utilities.LogError(ex); throw; } finally { // Close the connection command.Connection.Close(); } // return the number of affected rows return affectedRows; } // execute a select command and return a single result as a string public static string ExecuteScalar(DbCommand command) { // The value to be returned string value = ""; // Execute the command making sure the connection gets closed in the end try { // Open the connection of the command command.Connection.Open(); // Execute the command and get the number of affected rows value = command.ExecuteScalar().ToString(); } catch (Exception ex) { // Log eventual errors and rethrow them Utilities.LogError(ex); throw; } finally { // Close the connection command.Connection.Close(); } // return the result return value; } }
014-01-elegantfood
trunk/App_Code/GenericDataAccess.cs
C#
mit
3,788
using System; /// <summary> /// Class EF_ProductProperty holds all the column name of product table /// </summary> public class EF_ProductProperty { public EF_ProductProperty() { // // TODO: Add constructor logic here // } public Int32 ProductID { get; set; } public Guid UserID { get; set; } public string Name { get; set; } public string Description { get; set; } public decimal Price { get; set; } public decimal SpecialPrice { get; set; } public string Thumbnail { get; set; } public string Image { get; set; } public DateTime CreateDate { get; set; } public DateTime ModifyDate { get; set; } public bool Status { get; set; } public bool HightLight { get; set; } public bool Promotion { get; set; } }
014-01-elegantfood
trunk/App_Code/EF_ProductProperty.cs
C#
mit
912
using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Data.Common; using System.Data; /// <summary> /// Summary description for ShoppingCartAccess /// </summary> public class ShoppingCartAccess { public ShoppingCartAccess() { // // TODO: Add constructor logic here // } // returns the shopping cart ID for the current user private static string shoppingCartId { get { // get the current HttpContext HttpContext context = HttpContext.Current; // try to retrieve the cart ID from the user cookie //string cartId = context.Request.Cookies["ElegantFood_CartID"].Value; string cartId; // if the cart ID isn't in the cookie... { // check if the cart ID exists as a cookie if (context.Request.Cookies["ElegantFood_CartID"] != null) { cartId = context.Request.Cookies["ElegantFood_CartID"].Value; // return the id return cartId; } else // if the cart ID doesn't exist in the cookie as well, generate // a new ID { // generate a new GUID cartId = Guid.NewGuid().ToString(); // create the cookie object and set its value HttpCookie cookie = new HttpCookie("ElegantFood_CartID", cartId); // set the cookie's expiration date int howManyDays = ElegantFoodConfiguration.CartPersistDays; DateTime currentDate = DateTime.Now; TimeSpan timeSpan = new TimeSpan(howManyDays, 0, 0, 0); DateTime expirationDate = currentDate.Add(timeSpan); cookie.Expires = expirationDate; // set the cookie on the client's browser context.Response.Cookies.Add(cookie); // return the CartID return cartId.ToString(); } } } } // Add a new shopping cart item public static bool AddItem(string productId) { // get a configured DbCommand object DbCommand cmd = GenericDataAccess.CreateCommand(); // set the stored procedure name cmd.CommandText = "EF_ShoppingCartAddItem"; // create a new parameter DbParameter param = cmd.CreateParameter(); param.ParameterName = "@CartID"; param.Value = shoppingCartId; param.DbType = DbType.String; param.Size = 36; cmd.Parameters.Add(param); // create a new parameter param = cmd.CreateParameter(); param.ParameterName = "@ProductID"; param.Value = productId; param.DbType = DbType.Int32; cmd.Parameters.Add(param); // returns true in case of success and false in case of an error try { // execute the stored procedure and return true if it executes // successfully, and false otherwise return (GenericDataAccess.ExecuteNonQuery(cmd) != -1); } catch { // prevent the exception from propagating, but return false to // signal the error return false; } } // Update the quantity of a shopping cart item public static bool UpdateItem(string productId, int quantity) { // get a configured DbCommand object DbCommand cmd = GenericDataAccess.CreateCommand(); // set the stored procedure name cmd.CommandText = "EF_ShoppingCartUpdateItem"; // create a new parameter DbParameter param = cmd.CreateParameter(); param.ParameterName = "@CartID"; param.Value = shoppingCartId; param.DbType = DbType.String; param.Size = 36; cmd.Parameters.Add(param); // create a new parameter param = cmd.CreateParameter(); param.ParameterName = "@ProductID"; param.Value = productId; param.DbType = DbType.Int32; cmd.Parameters.Add(param); // create a new parameter param = cmd.CreateParameter(); param.ParameterName = "@Quantity"; param.Value = quantity; param.DbType = DbType.Int32; cmd.Parameters.Add(param); // returns true in case of success and false in case of an error try { // execute the stored procedure and return true if it executes // successfully, and false otherwise return (GenericDataAccess.ExecuteNonQuery(cmd) != -1); } catch { // prevent the exception from propagating, but return false to // signal the error return false; } } // Remove a shopping cart item public static bool RemoveItem(string productId) { // get a configured DbCommand object DbCommand cmd = GenericDataAccess.CreateCommand(); // set the stored procedure name cmd.CommandText = "EF_ShoppingCartRemoveItem"; // create a new parameter DbParameter param = cmd.CreateParameter(); param.ParameterName = "@CartID"; param.Value = shoppingCartId; param.DbType = DbType.String; param.Size = 36; cmd.Parameters.Add(param); // create a new parameter param = cmd.CreateParameter(); param.ParameterName = "@ProductID"; param.Value = productId; param.DbType = DbType.Int32; cmd.Parameters.Add(param); // returns true in case of success and false in case of an error try { // execute the stored procedure and return true if it executes // successfully, and false otherwise return (GenericDataAccess.ExecuteNonQuery(cmd) != -1); } catch { // prevent the exception from propagating, but return false to // signal the error return false; } } // Retrieve shopping cart items public static DataTable GetItems() { // get a configured DbCommand object DbCommand cmd = GenericDataAccess.CreateCommand(); // set the stored procedure name cmd.CommandText = "EF_ShoppingCartGetItems"; // create a new parameter DbParameter param = cmd.CreateParameter(); param.ParameterName = "@CartID"; param.Value = shoppingCartId; param.DbType = DbType.String; param.Size = 36; cmd.Parameters.Add(param); // return the result table DataTable table = GenericDataAccess.ExecuteSelectCommand(cmd); return table; } // Retrieve shopping cart items public static decimal GetTotalAmount() { // get a configured DbCommand object DbCommand cmd = GenericDataAccess.CreateCommand(); // set the stored procedure name cmd.CommandText = "EF_ShoppingCartGetTotalAmount"; // create a new parameter DbParameter param = cmd.CreateParameter(); param.ParameterName = "@CartID"; param.Value = shoppingCartId; param.DbType = DbType.String; param.Size = 36; cmd.Parameters.Add(param); // return the result table return Decimal.Parse(GenericDataAccess.ExecuteScalar(cmd)); } // Retrieve shopping cart items public static Int32 GetTotalItem() { // get a configured DbCommand object DbCommand cmd = GenericDataAccess.CreateCommand(); // set the stored procedure name cmd.CommandText = "EF_ShoppingCartGetTotalItem"; // create a new parameter DbParameter param = cmd.CreateParameter(); param.ParameterName = "@CartID"; param.Value = shoppingCartId; param.DbType = DbType.String; param.Size = 36; cmd.Parameters.Add(param); // return the result table return Int32.Parse(GenericDataAccess.ExecuteScalar(cmd)); } // Create a new order from the shopping cart public static bool CreateOrder(EF_CustomerProperty customer) { // get a configured DbCommand object DbCommand cmd = GenericDataAccess.CreateCommand(); // set the stored procedure name cmd.CommandText = "EF_CreateOrder"; // create a new parameter DbParameter CartParam = cmd.CreateParameter(); CartParam.ParameterName = "@CartID"; CartParam.Value = shoppingCartId; CartParam.DbType = DbType.String; CartParam.Size = 36; cmd.Parameters.Add(CartParam); CartParam = cmd.CreateParameter(); CartParam.ParameterName = "@CustomerName"; CartParam.Value = customer.CustomerName; CartParam.DbType = DbType.String; cmd.Parameters.Add(CartParam); CartParam = cmd.CreateParameter(); CartParam.ParameterName = "@CustomerPhone"; CartParam.Value = customer.CustomerPhone; CartParam.DbType = DbType.String; cmd.Parameters.Add(CartParam); CartParam = cmd.CreateParameter(); CartParam.ParameterName = "@CustomerEmail"; CartParam.Value = customer.CustomerEmail; CartParam.DbType = DbType.String; cmd.Parameters.Add(CartParam); CartParam = cmd.CreateParameter(); CartParam.ParameterName = "@ShippingAddress"; CartParam.Value = customer.ShippingAddress; CartParam.DbType = DbType.String; cmd.Parameters.Add(CartParam); return GenericDataAccess.ExecuteCommand(cmd); } }
014-01-elegantfood
trunk/App_Code/ShoppingCartAccess.cs
C#
mit
8,370
using System; /// <summary> /// Class EF_CategoryProperty holds all the column name of category table /// </summary> public class EF_CategoryProperty { public Int32 CategoryID { get; set; } public string UserID { get; set; } public string Name { get; set; } public string Description { get; set; } public DateTime CreateDate { get; set; } public DateTime ModifyDate { get; set; } public bool Status { get; set; } }
014-01-elegantfood
trunk/App_Code/EF_CategoryProperty.cs
C#
mit
523
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
014-01-elegantfood
trunk/Uploads/Thumbnails/index.html
HTML
mit
114
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
014-01-elegantfood
trunk/Uploads/index.html
HTML
mit
114
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
014-01-elegantfood
trunk/App_Data/index.html
HTML
mit
114
<%@ Page Language="C#" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <script runat="server"> </script> <html xmlns="http://www.w3.org/1999/xhtml"> <head runat="server"> <title>Error 404 - Page Not Found</title> </head> <body> <form id="form1" runat="server"> <div> </div> </form> </body> </html>
014-01-elegantfood
trunk/Oops.aspx
ASP.NET
mit
425
<%@ Page Title="" Language="C#" MasterPageFile="~/Site/ElegantFood.master" %> <script runat="server"> </script> <asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server"> </asp:Content> <asp:Content ID="Content2" ContentPlaceHolderID="ImageBanner" runat="server"> <img src="../App_Resources/Images/banner1.jpg" alt="Banner1" width="1140" /> </asp:Content> <asp:Content ID="Content4" ContentPlaceHolderID="ProductHeading" runat="server"> <h2> អាហារថ្មីសម្រាប់ថ្ងៃនេះ </h2> </asp:Content> <asp:Content ID="Content3" ContentPlaceHolderID="ContentElegantFood" runat="Server"> <efx:ProductFrontHightLightList ID="productHightLight" runat="server" /> </asp:Content>
014-01-elegantfood
trunk/Default.aspx
ASP.NET
mit
745
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
00-techstorm
trunk/application/config/index.html
HTML
gpl3
114
<?php if (!defined('BASEPATH')) exit('No direct script access allowed'); /* | ------------------------------------------------------------------- | DATABASE CONNECTIVITY SETTINGS | ------------------------------------------------------------------- | This file will contain the settings needed to access your database. | | For complete instructions please consult the 'Database Connection' | page of the User Guide. | | ------------------------------------------------------------------- | EXPLANATION OF VARIABLES | ------------------------------------------------------------------- | | ['hostname'] The hostname of your database server. | ['username'] The username used to connect to the database | ['password'] The password used to connect to the database | ['database'] The name of the database you want to connect to | ['dbdriver'] The database type. ie: mysql. Currently supported: mysql, mysqli, postgre, odbc, mssql, sqlite, oci8 | ['dbprefix'] You can add an optional prefix, which will be added | to the table name when using the Active Record class | ['pconnect'] TRUE/FALSE - Whether to use a persistent connection | ['db_debug'] TRUE/FALSE - Whether database errors should be displayed. | ['cache_on'] TRUE/FALSE - Enables/disables query caching | ['cachedir'] The path to the folder where cache files should be stored | ['char_set'] The character set used in communicating with the database | ['dbcollat'] The character collation used in communicating with the database | NOTE: For MySQL and MySQLi databases, this setting is only used | as a backup if your server is running PHP < 5.2.3 or MySQL < 5.0.7 | (and in table creation queries made with DB Forge). | There is an incompatibility in PHP with mysql_real_escape_string() which | can make your site vulnerable to SQL injection if you are using a | multi-byte character set and are running versions lower than these. | Sites using Latin-1 or UTF-8 database character set and collation are unaffected. | ['swap_pre'] A default table prefix that should be swapped with the dbprefix | ['autoinit'] Whether or not to automatically initialize the database. | ['stricton'] TRUE/FALSE - forces 'Strict Mode' connections | - good for ensuring strict SQL while developing | | The $active_group variable lets you choose which connection group to | make active. By default there is only one group (the 'default' group). | | The $active_record variables lets you determine whether or not to load | the active record class */ $active_group = 'default'; $active_record = TRUE; $db['default']['hostname'] = 'localhost'; $db['default']['username'] = 'techstor_admin'; $db['default']['password'] = 'techstorm'; $db['default']['database'] = 'techstor_techstorm'; $db['default']['dbdriver'] = 'mysqli'; $db['default']['dbprefix'] = ''; $db['default']['pconnect'] = TRUE; $db['default']['db_debug'] = TRUE; $db['default']['cache_on'] = FALSE; $db['default']['cachedir'] = ''; $db['default']['char_set'] = 'utf8'; $db['default']['dbcollat'] = 'utf8_general_ci'; $db['default']['swap_pre'] = ''; $db['default']['autoinit'] = TRUE; $db['default']['stricton'] = FALSE; /* End of file database.php */ /* Location: ./application/config/database.php */
00-techstorm
trunk/application/config/database.php
PHP
gpl3
3,337
<?php if (!defined('BASEPATH')) exit('No direct script access allowed'); /* | ------------------------------------------------------------------------- | URI ROUTING | ------------------------------------------------------------------------- | This file lets you re-map URI requests to specific controller functions. | | Typically there is a one-to-one relationship between a URL string | and its corresponding controller class/method. The segments in a | URL normally follow this pattern: | | example.com/class/method/id/ | | In some instances, however, you may want to remap this relationship | so that a different class/function is called than the one | corresponding to the URL. | | Please see the user guide for complete details: | | http://codeigniter.com/user_guide/general/routing.html | | ------------------------------------------------------------------------- | RESERVED ROUTES | ------------------------------------------------------------------------- | | There area two reserved routes: | | $route['default_controller'] = 'welcome'; | | This route indicates which controller class should be loaded if the | URI contains no data. In the above example, the "welcome" class | would be loaded. | | $route['404_override'] = 'errors/page_missing'; | | This route will tell the Router what URI segments to use if those provided | in the URL cannot be matched to a valid route. | */ $route['default_controller'] = "home"; $route['404_override'] = ''; $route['admin'] = 'admin/dashboard/index'; /* End of file routes.php */ /* Location: ./application/config/routes.php */
00-techstorm
trunk/application/config/routes.php
PHP
gpl3
1,658
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); /* |-------------------------------------------------------------------------- | File and Directory Modes |-------------------------------------------------------------------------- | | These prefs are used when checking and setting modes when working | with the file system. The defaults are fine on servers with proper | security, but you may wish (or even need) to change the values in | certain environments (Apache running a separate process for each | user, PHP under CGI with Apache suEXEC, etc.). Octal values should | always be used to set the mode correctly. | */ define('FILE_READ_MODE', 0644); define('FILE_WRITE_MODE', 0666); define('DIR_READ_MODE', 0755); define('DIR_WRITE_MODE', 0777); /* |-------------------------------------------------------------------------- | File Stream Modes |-------------------------------------------------------------------------- | | These modes are used when working with fopen()/popen() | */ define('FOPEN_READ', 'rb'); define('FOPEN_READ_WRITE', 'r+b'); define('FOPEN_WRITE_CREATE_DESTRUCTIVE', 'wb'); // truncates existing file data, use with care define('FOPEN_READ_WRITE_CREATE_DESTRUCTIVE', 'w+b'); // truncates existing file data, use with care define('FOPEN_WRITE_CREATE', 'ab'); define('FOPEN_READ_WRITE_CREATE', 'a+b'); define('FOPEN_WRITE_CREATE_STRICT', 'xb'); define('FOPEN_READ_WRITE_CREATE_STRICT', 'x+b'); /* End of file constants.php */ /* Location: ./application/config/constants.php */
00-techstorm
trunk/application/config/constants.php
PHP
gpl3
1,558
<?php if (!defined('BASEPATH')) exit('No direct script access allowed'); /* |-------------------------------------------------------------------------- | Base Site URL |-------------------------------------------------------------------------- | | URL to your CodeIgniter root. Typically this will be your base URL, | WITH a trailing slash: | | http://example.com/ | | If this is not set then CodeIgniter will guess the protocol, domain and | path to your installation. | */ $config['base_url'] = ''; /* |-------------------------------------------------------------------------- | Index File |-------------------------------------------------------------------------- | | Typically this will be your index.php file, unless you've renamed it to | something else. If you are using mod_rewrite to remove the page set this | variable so that it is blank. | */ //$config['index_page'] = 'index.php'; $config['index_page'] = ''; /* |-------------------------------------------------------------------------- | URI PROTOCOL |-------------------------------------------------------------------------- | | This item determines which server global should be used to retrieve the | URI string. The default setting of 'AUTO' works for most servers. | If your links do not seem to work, try one of the other delicious flavors: | | 'AUTO' Default - auto detects | 'PATH_INFO' Uses the PATH_INFO | 'QUERY_STRING' Uses the QUERY_STRING | 'REQUEST_URI' Uses the REQUEST_URI | 'ORIG_PATH_INFO' Uses the ORIG_PATH_INFO | */ $config['uri_protocol'] = 'AUTO'; /* |-------------------------------------------------------------------------- | URL suffix |-------------------------------------------------------------------------- | | This option allows you to add a suffix to all URLs generated by CodeIgniter. | For more information please see the user guide: | | http://codeigniter.com/user_guide/general/urls.html */ $config['url_suffix'] = ''; /* |-------------------------------------------------------------------------- | Default Language |-------------------------------------------------------------------------- | | This determines which set of language files should be used. Make sure | there is an available translation if you intend to use something other | than english. | */ $config['language'] = 'english'; /* |-------------------------------------------------------------------------- | Default Character Set |-------------------------------------------------------------------------- | | This determines which character set is used by default in various methods | that require a character set to be provided. | */ $config['charset'] = 'UTF-8'; /* |-------------------------------------------------------------------------- | Enable/Disable System Hooks |-------------------------------------------------------------------------- | | If you would like to use the 'hooks' feature you must enable it by | setting this variable to TRUE (boolean). See the user guide for details. | */ $config['enable_hooks'] = FALSE; /* |-------------------------------------------------------------------------- | Class Extension Prefix |-------------------------------------------------------------------------- | | This item allows you to set the filename/classname prefix when extending | native libraries. For more information please see the user guide: | | http://codeigniter.com/user_guide/general/core_classes.html | http://codeigniter.com/user_guide/general/creating_libraries.html | */ $config['subclass_prefix'] = 'MY_'; /* |-------------------------------------------------------------------------- | Allowed URL Characters |-------------------------------------------------------------------------- | | This lets you specify with a regular expression which characters are permitted | within your URLs. When someone tries to submit a URL with disallowed | characters they will get a warning message. | | As a security measure you are STRONGLY encouraged to restrict URLs to | as few characters as possible. By default only these are allowed: a-z 0-9~%.:_- | | Leave blank to allow all characters -- but only if you are insane. | | DO NOT CHANGE THIS UNLESS YOU FULLY UNDERSTAND THE REPERCUSSIONS!! | */ $config['permitted_uri_chars'] = 'a-z 0-9~%.:_\-'; /* |-------------------------------------------------------------------------- | Enable Query Strings |-------------------------------------------------------------------------- | | By default CodeIgniter uses search-engine friendly segment based URLs: | example.com/who/what/where/ | | By default CodeIgniter enables access to the $_GET array. If for some | reason you would like to disable it, set 'allow_get_array' to FALSE. | | You can optionally enable standard query string based URLs: | example.com?who=me&what=something&where=here | | Options are: TRUE or FALSE (boolean) | | The other items let you set the query string 'words' that will | invoke your controllers and its functions: | example.com/index.php?c=controller&m=function | | Please note that some of the helpers won't work as expected when | this feature is enabled, since CodeIgniter is designed primarily to | use segment based URLs. | */ $config['allow_get_array'] = TRUE; $config['enable_query_strings'] = FALSE; $config['controller_trigger'] = 'c'; $config['function_trigger'] = 'm'; $config['directory_trigger'] = 'd'; // experimental not currently in use /* |-------------------------------------------------------------------------- | Error Logging Threshold |-------------------------------------------------------------------------- | | If you have enabled error logging, you can set an error threshold to | determine what gets logged. Threshold options are: | You can enable error logging by setting a threshold over zero. The | threshold determines what gets logged. Threshold options are: | | 0 = Disables logging, Error logging TURNED OFF | 1 = Error Messages (including PHP errors) | 2 = Debug Messages | 3 = Informational Messages | 4 = All Messages | | For a live site you'll usually only enable Errors (1) to be logged otherwise | your log files will fill up very fast. | */ $config['log_threshold'] = 0; /* |-------------------------------------------------------------------------- | Error Logging Directory Path |-------------------------------------------------------------------------- | | Leave this BLANK unless you would like to set something other than the default | application/logs/ folder. Use a full server path with trailing slash. | */ $config['log_path'] = ''; /* |-------------------------------------------------------------------------- | Date Format for Logs |-------------------------------------------------------------------------- | | Each item that is logged has an associated date. You can use PHP date | codes to set your own date formatting | */ $config['log_date_format'] = 'Y-m-d H:i:s'; /* |-------------------------------------------------------------------------- | Cache Directory Path |-------------------------------------------------------------------------- | | Leave this BLANK unless you would like to set something other than the default | system/cache/ folder. Use a full server path with trailing slash. | */ $config['cache_path'] = ''; /* |-------------------------------------------------------------------------- | Encryption Key |-------------------------------------------------------------------------- | | If you use the Encryption class or the Session class you | MUST set an encryption key. See the user guide for info. | */ $config['encryption_key'] = 'techstorm'; /* |-------------------------------------------------------------------------- | Session Variables |-------------------------------------------------------------------------- | | 'sess_cookie_name' = the name you want for the cookie | 'sess_expiration' = the number of SECONDS you want the session to last. | by default sessions last 7200 seconds (two hours). Set to zero for no expiration. | 'sess_expire_on_close' = Whether to cause the session to expire automatically | when the browser window is closed | 'sess_encrypt_cookie' = Whether to encrypt the cookie | 'sess_use_database' = Whether to save the session data to a database | 'sess_table_name' = The name of the session database table | 'sess_match_ip' = Whether to match the user's IP address when reading the session data | 'sess_match_useragent' = Whether to match the User Agent when reading the session data | 'sess_time_to_update' = how many seconds between CI refreshing Session Information | */ $config['sess_cookie_name'] = 'ci_session'; $config['sess_expiration'] = 7200; $config['sess_expire_on_close'] = FALSE; $config['sess_encrypt_cookie'] = FALSE; $config['sess_use_database'] = FALSE; $config['sess_table_name'] = 'ci_sessions'; $config['sess_match_ip'] = FALSE; $config['sess_match_useragent'] = TRUE; $config['sess_time_to_update'] = 300; /* |-------------------------------------------------------------------------- | Cookie Related Variables |-------------------------------------------------------------------------- | | 'cookie_prefix' = Set a prefix if you need to avoid collisions | 'cookie_domain' = Set to .your-domain.com for site-wide cookies | 'cookie_path' = Typically will be a forward slash | 'cookie_secure' = Cookies will only be set if a secure HTTPS connection exists. | */ $config['cookie_prefix'] = ""; $config['cookie_domain'] = ""; $config['cookie_path'] = "/"; $config['cookie_secure'] = FALSE; /* |-------------------------------------------------------------------------- | Global XSS Filtering |-------------------------------------------------------------------------- | | Determines whether the XSS filter is always active when GET, POST or | COOKIE data is encountered | */ $config['global_xss_filtering'] = FALSE; /* |-------------------------------------------------------------------------- | Cross Site Request Forgery |-------------------------------------------------------------------------- | Enables a CSRF cookie token to be set. When set to TRUE, token will be | checked on a submitted form. If you are accepting user data, it is strongly | recommended CSRF protection be enabled. | | 'csrf_token_name' = The token name | 'csrf_cookie_name' = The cookie name | 'csrf_expire' = The number in seconds the token should expire. */ $config['csrf_protection'] = FALSE; $config['csrf_token_name'] = 'csrf_test_name'; $config['csrf_cookie_name'] = 'csrf_cookie_name'; $config['csrf_expire'] = 7200; /* |-------------------------------------------------------------------------- | Output Compression |-------------------------------------------------------------------------- | | Enables Gzip output compression for faster page loads. When enabled, | the output class will test whether your server supports Gzip. | Even if it does, however, not all browsers support compression | so enable only if you are reasonably sure your visitors can handle it. | | VERY IMPORTANT: If you are getting a blank page when compression is enabled it | means you are prematurely outputting something to your browser. It could | even be a line of whitespace at the end of one of your scripts. For | compression to work, nothing can be sent before the output buffer is called | by the output class. Do not 'echo' any values with compression enabled. | */ $config['compress_output'] = FALSE; /* |-------------------------------------------------------------------------- | Master Time Reference |-------------------------------------------------------------------------- | | Options are 'local' or 'gmt'. This pref tells the system whether to use | your server's local time as the master 'now' reference, or convert it to | GMT. See the 'date helper' page of the user guide for information | regarding date handling. | */ $config['time_reference'] = 'local'; /* |-------------------------------------------------------------------------- | Rewrite PHP Short Tags |-------------------------------------------------------------------------- | | If your PHP installation does not have short tag support enabled CI | can rewrite the tags on-the-fly, enabling you to utilize that syntax | in your view files. Options are TRUE or FALSE (boolean) | */ $config['rewrite_short_tags'] = FALSE; /* |-------------------------------------------------------------------------- | Reverse Proxy IPs |-------------------------------------------------------------------------- | | If your server is behind a reverse proxy, you must whitelist the proxy IP | addresses from which CodeIgniter should trust the HTTP_X_FORWARDED_FOR | header in order to properly identify the visitor's IP address. | Comma-delimited, e.g. '10.0.1.200,10.0.1.201' | */ $config['proxy_ips'] = ''; /* End of file config.php */ /* Location: ./application/config/config.php */
00-techstorm
trunk/application/config/config.php
PHP
gpl3
13,346
<?php if (!defined('BASEPATH')) exit('No direct script access allowed'); /* | ------------------------------------------------------------------- | AUTO-LOADER | ------------------------------------------------------------------- | This file specifies which systems should be loaded by default. | | In order to keep the framework as light-weight as possible only the | absolute minimal resources are loaded by default. For example, | the database is not connected to automatically since no assumption | is made regarding whether you intend to use it. This file lets | you globally define which systems you would like loaded with every | request. | | ------------------------------------------------------------------- | Instructions | ------------------------------------------------------------------- | | These are the things you can load automatically: | | 1. Packages | 2. Libraries | 3. Helper files | 4. Custom config files | 5. Language files | 6. Models | */ /* | ------------------------------------------------------------------- | Auto-load Packges | ------------------------------------------------------------------- | Prototype: | | $autoload['packages'] = array(APPPATH.'third_party', '/usr/local/shared'); | */ $autoload['packages'] = array(); /* | ------------------------------------------------------------------- | Auto-load Libraries | ------------------------------------------------------------------- | These are the classes located in the system/libraries folder | or in your application/libraries folder. | | Prototype: | | $autoload['libraries'] = array('database', 'session', 'xmlrpc'); */ $autoload['libraries'] = array('database', 'session'); /* | ------------------------------------------------------------------- | Auto-load Helper Files | ------------------------------------------------------------------- | Prototype: | | $autoload['helper'] = array('url', 'file'); */ $autoload['helper'] = array(); /* | ------------------------------------------------------------------- | Auto-load Config files | ------------------------------------------------------------------- | Prototype: | | $autoload['config'] = array('config1', 'config2'); | | NOTE: This item is intended for use ONLY if you have created custom | config files. Otherwise, leave it blank. | */ $autoload['config'] = array(); /* | ------------------------------------------------------------------- | Auto-load Language files | ------------------------------------------------------------------- | Prototype: | | $autoload['language'] = array('lang1', 'lang2'); | | NOTE: Do not include the "_lang" part of your file. For example | "codeigniter_lang.php" would be referenced as array('codeigniter'); | */ $autoload['language'] = array(); /* | ------------------------------------------------------------------- | Auto-load Models | ------------------------------------------------------------------- | Prototype: | | $autoload['model'] = array('model1', 'model2'); | */ $autoload['model'] = array(); /* End of file autoload.php */ /* Location: ./application/config/autoload.php */
00-techstorm
trunk/application/config/autoload.php
PHP
gpl3
3,266
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); /* | ------------------------------------------------------------------- | MIME TYPES | ------------------------------------------------------------------- | This file contains an array of mime types. It is used by the | Upload class to help identify allowed file types. | */ $mimes = array( 'hqx' => 'application/mac-binhex40', 'cpt' => 'application/mac-compactpro', 'csv' => array('text/x-comma-separated-values', 'text/comma-separated-values', 'application/octet-stream', 'application/vnd.ms-excel', 'application/x-csv', 'text/x-csv', 'text/csv', 'application/csv', 'application/excel', 'application/vnd.msexcel'), 'bin' => 'application/macbinary', 'dms' => 'application/octet-stream', 'lha' => 'application/octet-stream', 'lzh' => 'application/octet-stream', 'exe' => array('application/octet-stream', 'application/x-msdownload'), 'class' => 'application/octet-stream', 'psd' => 'application/x-photoshop', 'so' => 'application/octet-stream', 'sea' => 'application/octet-stream', 'dll' => 'application/octet-stream', 'oda' => 'application/oda', 'pdf' => array('application/pdf', 'application/x-download'), 'ai' => 'application/postscript', 'eps' => 'application/postscript', 'ps' => 'application/postscript', 'smi' => 'application/smil', 'smil' => 'application/smil', 'mif' => 'application/vnd.mif', 'xls' => array('application/excel', 'application/vnd.ms-excel', 'application/msexcel'), 'ppt' => array('application/powerpoint', 'application/vnd.ms-powerpoint'), 'wbxml' => 'application/wbxml', 'wmlc' => 'application/wmlc', 'dcr' => 'application/x-director', 'dir' => 'application/x-director', 'dxr' => 'application/x-director', 'dvi' => 'application/x-dvi', 'gtar' => 'application/x-gtar', 'gz' => 'application/x-gzip', 'php' => 'application/x-httpd-php', 'php4' => 'application/x-httpd-php', 'php3' => 'application/x-httpd-php', 'phtml' => 'application/x-httpd-php', 'phps' => 'application/x-httpd-php-source', 'js' => 'application/x-javascript', 'swf' => 'application/x-shockwave-flash', 'sit' => 'application/x-stuffit', 'tar' => 'application/x-tar', 'tgz' => array('application/x-tar', 'application/x-gzip-compressed'), 'xhtml' => 'application/xhtml+xml', 'xht' => 'application/xhtml+xml', 'zip' => array('application/x-zip', 'application/zip', 'application/x-zip-compressed'), 'mid' => 'audio/midi', 'midi' => 'audio/midi', 'mpga' => 'audio/mpeg', 'mp2' => 'audio/mpeg', 'mp3' => array('audio/mpeg', 'audio/mpg', 'audio/mpeg3', 'audio/mp3'), 'aif' => 'audio/x-aiff', 'aiff' => 'audio/x-aiff', 'aifc' => 'audio/x-aiff', 'ram' => 'audio/x-pn-realaudio', 'rm' => 'audio/x-pn-realaudio', 'rpm' => 'audio/x-pn-realaudio-plugin', 'ra' => 'audio/x-realaudio', 'rv' => 'video/vnd.rn-realvideo', 'wav' => array('audio/x-wav', 'audio/wave', 'audio/wav'), 'bmp' => array('image/bmp', 'image/x-windows-bmp'), 'gif' => 'image/gif', 'jpeg' => array('image/jpeg', 'image/pjpeg'), 'jpg' => array('image/jpeg', 'image/pjpeg'), 'jpe' => array('image/jpeg', 'image/pjpeg'), 'png' => array('image/png', 'image/x-png'), 'tiff' => 'image/tiff', 'tif' => 'image/tiff', 'css' => 'text/css', 'html' => 'text/html', 'htm' => 'text/html', 'shtml' => 'text/html', 'txt' => 'text/plain', 'text' => 'text/plain', 'log' => array('text/plain', 'text/x-log'), 'rtx' => 'text/richtext', 'rtf' => 'text/rtf', 'xml' => 'text/xml', 'xsl' => 'text/xml', 'mpeg' => 'video/mpeg', 'mpg' => 'video/mpeg', 'mpe' => 'video/mpeg', 'qt' => 'video/quicktime', 'mov' => 'video/quicktime', 'avi' => 'video/x-msvideo', 'movie' => 'video/x-sgi-movie', 'doc' => 'application/msword', 'docx' => array('application/vnd.openxmlformats-officedocument.wordprocessingml.document', 'application/zip'), 'xlsx' => array('application/vnd.openxmlformats-officedocument.spreadsheetml.sheet', 'application/zip'), 'word' => array('application/msword', 'application/octet-stream'), 'xl' => 'application/excel', 'eml' => 'message/rfc822', 'json' => array('application/json', 'text/json') ); /* End of file mimes.php */ /* Location: ./application/config/mimes.php */
00-techstorm
trunk/application/config/mimes.php
PHP
gpl3
4,453
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); /* | ------------------------------------------------------------------- | Foreign Characters | ------------------------------------------------------------------- | This file contains an array of foreign characters for transliteration | conversion used by the Text helper | */ $foreign_characters = array( '/ä|æ|ǽ/' => 'ae', '/ö|œ/' => 'oe', '/ü/' => 'ue', '/Ä/' => 'Ae', '/Ü/' => 'Ue', '/Ö/' => 'Oe', '/À|Á|Â|Ã|Ä|Å|Ǻ|Ā|Ă|Ą|Ǎ/' => 'A', '/à|á|â|ã|å|ǻ|ā|ă|ą|ǎ|ª/' => 'a', '/Ç|Ć|Ĉ|Ċ|Č/' => 'C', '/ç|ć|ĉ|ċ|č/' => 'c', '/Ð|Ď|Đ/' => 'D', '/ð|ď|đ/' => 'd', '/È|É|Ê|Ë|Ē|Ĕ|Ė|Ę|Ě/' => 'E', '/è|é|ê|ë|ē|ĕ|ė|ę|ě/' => 'e', '/Ĝ|Ğ|Ġ|Ģ/' => 'G', '/ĝ|ğ|ġ|ģ/' => 'g', '/Ĥ|Ħ/' => 'H', '/ĥ|ħ/' => 'h', '/Ì|Í|Î|Ï|Ĩ|Ī|Ĭ|Ǐ|Į|İ/' => 'I', '/ì|í|î|ï|ĩ|ī|ĭ|ǐ|į|ı/' => 'i', '/Ĵ/' => 'J', '/ĵ/' => 'j', '/Ķ/' => 'K', '/ķ/' => 'k', '/Ĺ|Ļ|Ľ|Ŀ|Ł/' => 'L', '/ĺ|ļ|ľ|ŀ|ł/' => 'l', '/Ñ|Ń|Ņ|Ň/' => 'N', '/ñ|ń|ņ|ň|ʼn/' => 'n', '/Ò|Ó|Ô|Õ|Ō|Ŏ|Ǒ|Ő|Ơ|Ø|Ǿ/' => 'O', '/ò|ó|ô|õ|ō|ŏ|ǒ|ő|ơ|ø|ǿ|º/' => 'o', '/Ŕ|Ŗ|Ř/' => 'R', '/ŕ|ŗ|ř/' => 'r', '/Ś|Ŝ|Ş|Š/' => 'S', '/ś|ŝ|ş|š|ſ/' => 's', '/Ţ|Ť|Ŧ/' => 'T', '/ţ|ť|ŧ/' => 't', '/Ù|Ú|Û|Ũ|Ū|Ŭ|Ů|Ű|Ų|Ư|Ǔ|Ǖ|Ǘ|Ǚ|Ǜ/' => 'U', '/ù|ú|û|ũ|ū|ŭ|ů|ű|ų|ư|ǔ|ǖ|ǘ|ǚ|ǜ/' => 'u', '/Ý|Ÿ|Ŷ/' => 'Y', '/ý|ÿ|ŷ/' => 'y', '/Ŵ/' => 'W', '/ŵ/' => 'w', '/Ź|Ż|Ž/' => 'Z', '/ź|ż|ž/' => 'z', '/Æ|Ǽ/' => 'AE', '/ß/'=> 'ss', '/IJ/' => 'IJ', '/ij/' => 'ij', '/Œ/' => 'OE', '/ƒ/' => 'f' ); /* End of file foreign_chars.php */ /* Location: ./application/config/foreign_chars.php */
00-techstorm
trunk/application/config/foreign_chars.php
PHP
gpl3
1,781
<?php defined('BASEPATH') OR exit('No direct script access allowed'); /* |-------------------------------------------------------------------------- | Enable/Disable Migrations |-------------------------------------------------------------------------- | | Migrations are disabled by default but should be enabled | whenever you intend to do a schema migration. | */ $config['migration_enabled'] = FALSE; /* |-------------------------------------------------------------------------- | Migrations version |-------------------------------------------------------------------------- | | This is used to set migration version that the file system should be on. | If you run $this->migration->latest() this is the version that schema will | be upgraded / downgraded to. | */ $config['migration_version'] = 0; /* |-------------------------------------------------------------------------- | Migrations Path |-------------------------------------------------------------------------- | | Path to your migrations folder. | Typically, it will be within your application path. | Also, writing permission is required within the migrations path. | */ $config['migration_path'] = APPPATH . 'migrations/'; /* End of file migration.php */ /* Location: ./application/config/migration.php */
00-techstorm
trunk/application/config/migration.php
PHP
gpl3
1,282
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); /* | ------------------------------------------------------------------- | USER AGENT TYPES | ------------------------------------------------------------------- | This file contains four arrays of user agent data. It is used by the | User Agent Class to help identify browser, platform, robot, and | mobile device data. The array keys are used to identify the device | and the array values are used to set the actual name of the item. | */ $platforms = array ( 'windows nt 6.0' => 'Windows Longhorn', 'windows nt 5.2' => 'Windows 2003', 'windows nt 5.0' => 'Windows 2000', 'windows nt 5.1' => 'Windows XP', 'windows nt 4.0' => 'Windows NT 4.0', 'winnt4.0' => 'Windows NT 4.0', 'winnt 4.0' => 'Windows NT', 'winnt' => 'Windows NT', 'windows 98' => 'Windows 98', 'win98' => 'Windows 98', 'windows 95' => 'Windows 95', 'win95' => 'Windows 95', 'windows' => 'Unknown Windows OS', 'os x' => 'Mac OS X', 'ppc mac' => 'Power PC Mac', 'freebsd' => 'FreeBSD', 'ppc' => 'Macintosh', 'linux' => 'Linux', 'debian' => 'Debian', 'sunos' => 'Sun Solaris', 'beos' => 'BeOS', 'apachebench' => 'ApacheBench', 'aix' => 'AIX', 'irix' => 'Irix', 'osf' => 'DEC OSF', 'hp-ux' => 'HP-UX', 'netbsd' => 'NetBSD', 'bsdi' => 'BSDi', 'openbsd' => 'OpenBSD', 'gnu' => 'GNU/Linux', 'unix' => 'Unknown Unix OS' ); // The order of this array should NOT be changed. Many browsers return // multiple browser types so we want to identify the sub-type first. $browsers = array( 'Flock' => 'Flock', 'Chrome' => 'Chrome', 'Opera' => 'Opera', 'MSIE' => 'Internet Explorer', 'Internet Explorer' => 'Internet Explorer', 'Shiira' => 'Shiira', 'Firefox' => 'Firefox', 'Chimera' => 'Chimera', 'Phoenix' => 'Phoenix', 'Firebird' => 'Firebird', 'Camino' => 'Camino', 'Netscape' => 'Netscape', 'OmniWeb' => 'OmniWeb', 'Safari' => 'Safari', 'Mozilla' => 'Mozilla', 'Konqueror' => 'Konqueror', 'icab' => 'iCab', 'Lynx' => 'Lynx', 'Links' => 'Links', 'hotjava' => 'HotJava', 'amaya' => 'Amaya', 'IBrowse' => 'IBrowse' ); $mobiles = array( // legacy array, old values commented out 'mobileexplorer' => 'Mobile Explorer', // 'openwave' => 'Open Wave', // 'opera mini' => 'Opera Mini', // 'operamini' => 'Opera Mini', // 'elaine' => 'Palm', 'palmsource' => 'Palm', // 'digital paths' => 'Palm', // 'avantgo' => 'Avantgo', // 'xiino' => 'Xiino', 'palmscape' => 'Palmscape', // 'nokia' => 'Nokia', // 'ericsson' => 'Ericsson', // 'blackberry' => 'BlackBerry', // 'motorola' => 'Motorola' // Phones and Manufacturers 'motorola' => "Motorola", 'nokia' => "Nokia", 'palm' => "Palm", 'iphone' => "Apple iPhone", 'ipad' => "iPad", 'ipod' => "Apple iPod Touch", 'sony' => "Sony Ericsson", 'ericsson' => "Sony Ericsson", 'blackberry' => "BlackBerry", 'cocoon' => "O2 Cocoon", 'blazer' => "Treo", 'lg' => "LG", 'amoi' => "Amoi", 'xda' => "XDA", 'mda' => "MDA", 'vario' => "Vario", 'htc' => "HTC", 'samsung' => "Samsung", 'sharp' => "Sharp", 'sie-' => "Siemens", 'alcatel' => "Alcatel", 'benq' => "BenQ", 'ipaq' => "HP iPaq", 'mot-' => "Motorola", 'playstation portable' => "PlayStation Portable", 'hiptop' => "Danger Hiptop", 'nec-' => "NEC", 'panasonic' => "Panasonic", 'philips' => "Philips", 'sagem' => "Sagem", 'sanyo' => "Sanyo", 'spv' => "SPV", 'zte' => "ZTE", 'sendo' => "Sendo", // Operating Systems 'symbian' => "Symbian", 'SymbianOS' => "SymbianOS", 'elaine' => "Palm", 'palm' => "Palm", 'series60' => "Symbian S60", 'windows ce' => "Windows CE", // Browsers 'obigo' => "Obigo", 'netfront' => "Netfront Browser", 'openwave' => "Openwave Browser", 'mobilexplorer' => "Mobile Explorer", 'operamini' => "Opera Mini", 'opera mini' => "Opera Mini", // Other 'digital paths' => "Digital Paths", 'avantgo' => "AvantGo", 'xiino' => "Xiino", 'novarra' => "Novarra Transcoder", 'vodafone' => "Vodafone", 'docomo' => "NTT DoCoMo", 'o2' => "O2", // Fallback 'mobile' => "Generic Mobile", 'wireless' => "Generic Mobile", 'j2me' => "Generic Mobile", 'midp' => "Generic Mobile", 'cldc' => "Generic Mobile", 'up.link' => "Generic Mobile", 'up.browser' => "Generic Mobile", 'smartphone' => "Generic Mobile", 'cellphone' => "Generic Mobile" ); // There are hundreds of bots but these are the most common. $robots = array( 'googlebot' => 'Googlebot', 'msnbot' => 'MSNBot', 'slurp' => 'Inktomi Slurp', 'yahoo' => 'Yahoo', 'askjeeves' => 'AskJeeves', 'fastcrawler' => 'FastCrawler', 'infoseek' => 'InfoSeek Robot 1.0', 'lycos' => 'Lycos' ); /* End of file user_agents.php */ /* Location: ./application/config/user_agents.php */
00-techstorm
trunk/application/config/user_agents.php
PHP
gpl3
5,589
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); /* | ------------------------------------------------------------------------- | Hooks | ------------------------------------------------------------------------- | This file lets you define "hooks" to extend CI without hacking the core | files. Please see the user guide for info: | | http://codeigniter.com/user_guide/general/hooks.html | */ /* End of file hooks.php */ /* Location: ./application/config/hooks.php */
00-techstorm
trunk/application/config/hooks.php
PHP
gpl3
498
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); /* | ------------------------------------------------------------------------- | Profiler Sections | ------------------------------------------------------------------------- | This file lets you determine whether or not various sections of Profiler | data are displayed when the Profiler is enabled. | Please see the user guide for info: | | http://codeigniter.com/user_guide/general/profiling.html | */ /* End of file profiler.php */ /* Location: ./application/config/profiler.php */
00-techstorm
trunk/application/config/profiler.php
PHP
gpl3
564
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); $_doctypes = array( 'xhtml11' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">', 'xhtml1-strict' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">', 'xhtml1-trans' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">', 'xhtml1-frame' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">', 'html5' => '<!DOCTYPE html>', 'html4-strict' => '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">', 'html4-trans' => '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">', 'html4-frame' => '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd">' ); /* End of file doctypes.php */ /* Location: ./application/config/doctypes.php */
00-techstorm
trunk/application/config/doctypes.php
PHP
gpl3
1,138
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); /* | ------------------------------------------------------------------- | SMILEYS | ------------------------------------------------------------------- | This file contains an array of smileys for use with the emoticon helper. | Individual images can be used to replace multiple simileys. For example: | :-) and :) use the same image replacement. | | Please see user guide for more info: | http://codeigniter.com/user_guide/helpers/smiley_helper.html | */ $smileys = array( // smiley image name width height alt ':-)' => array('grin.gif', '19', '19', 'grin'), ':lol:' => array('lol.gif', '19', '19', 'LOL'), ':cheese:' => array('cheese.gif', '19', '19', 'cheese'), ':)' => array('smile.gif', '19', '19', 'smile'), ';-)' => array('wink.gif', '19', '19', 'wink'), ';)' => array('wink.gif', '19', '19', 'wink'), ':smirk:' => array('smirk.gif', '19', '19', 'smirk'), ':roll:' => array('rolleyes.gif', '19', '19', 'rolleyes'), ':-S' => array('confused.gif', '19', '19', 'confused'), ':wow:' => array('surprise.gif', '19', '19', 'surprised'), ':bug:' => array('bigsurprise.gif', '19', '19', 'big surprise'), ':-P' => array('tongue_laugh.gif', '19', '19', 'tongue laugh'), '%-P' => array('tongue_rolleye.gif', '19', '19', 'tongue rolleye'), ';-P' => array('tongue_wink.gif', '19', '19', 'tongue wink'), ':P' => array('raspberry.gif', '19', '19', 'raspberry'), ':blank:' => array('blank.gif', '19', '19', 'blank stare'), ':long:' => array('longface.gif', '19', '19', 'long face'), ':ohh:' => array('ohh.gif', '19', '19', 'ohh'), ':grrr:' => array('grrr.gif', '19', '19', 'grrr'), ':gulp:' => array('gulp.gif', '19', '19', 'gulp'), '8-/' => array('ohoh.gif', '19', '19', 'oh oh'), ':down:' => array('downer.gif', '19', '19', 'downer'), ':red:' => array('embarrassed.gif', '19', '19', 'red face'), ':sick:' => array('sick.gif', '19', '19', 'sick'), ':shut:' => array('shuteye.gif', '19', '19', 'shut eye'), ':-/' => array('hmm.gif', '19', '19', 'hmmm'), '>:(' => array('mad.gif', '19', '19', 'mad'), ':mad:' => array('mad.gif', '19', '19', 'mad'), '>:-(' => array('angry.gif', '19', '19', 'angry'), ':angry:' => array('angry.gif', '19', '19', 'angry'), ':zip:' => array('zip.gif', '19', '19', 'zipper'), ':kiss:' => array('kiss.gif', '19', '19', 'kiss'), ':ahhh:' => array('shock.gif', '19', '19', 'shock'), ':coolsmile:' => array('shade_smile.gif', '19', '19', 'cool smile'), ':coolsmirk:' => array('shade_smirk.gif', '19', '19', 'cool smirk'), ':coolgrin:' => array('shade_grin.gif', '19', '19', 'cool grin'), ':coolhmm:' => array('shade_hmm.gif', '19', '19', 'cool hmm'), ':coolmad:' => array('shade_mad.gif', '19', '19', 'cool mad'), ':coolcheese:' => array('shade_cheese.gif', '19', '19', 'cool cheese'), ':vampire:' => array('vampire.gif', '19', '19', 'vampire'), ':snake:' => array('snake.gif', '19', '19', 'snake'), ':exclaim:' => array('exclaim.gif', '19', '19', 'excaim'), ':question:' => array('question.gif', '19', '19', 'question') // no comma after last item ); /* End of file smileys.php */ /* Location: ./application/config/smileys.php */
00-techstorm
trunk/application/config/smileys.php
PHP
gpl3
3,295
<div class="topic"> <div class="container"> <div class="row"> <div class="col-sm-4"> <h3>About Us</h3> </div> <div class="col-sm-8"> <ol class="breadcrumb pull-right hidden-xs"> <li><a href="index.html">Home</a></li> <li class="active">About Us</li> </ol> </div> </div> </div> </div> <div class="container"> <div class="row"> <div class="col-sm-12"> <h3 class="headline first-child"><span>TechStorm Solution - Professional Development Team</span></h3> <p> We are a team of freelancer,in our team we have more than 4 year of experience professionals. <br/> we are expertise in web development and mobile application development. </p> <hr> <?= anchor('home/contact', 'Contact Us', array('class' => 'btn btn-lg btn-red')); ?> <!--<a href="contact-us.html" class="btn btn-lg btn-red">Contact Us</a>--> <br><br> </div> </div> <!-- / .row --> </div>
00-techstorm
trunk/application/views/home/about.php
PHP
gpl3
1,161
<div class="topic"> <div class="container"> <div class="row"> <div class="col-sm-4"> <h3><?= $title ?></h3> </div> <div class="col-sm-8"> <ol class="breadcrumb pull-right hidden-xs"> <li><?= anchor('home/index', 'Home'); ?></li> <li class="active"><?= $title ?></li> </ol> </div> </div> </div> </div> <div class="container"> <div class="row"> <div class="col-sm-8"> <h3 class="headline first-child"><span>Contact Us</span></h3> <p>Please fill the form below to send an email to us.</p> <?= form_open('home/send_message'); ?> <div class="form-group"> <label for="txt_email">Your email address</label> <?= form_error('txt_email'); ?> <input type="text" name="txt_email" value="<?= set_value('txt_email'); ?>" class="form-control" placeholder="Enter email"> </div> <div class="form-group"> <label for="txt_name">Your name</label> <?= form_error('txt_name'); ?> <input type="text" name="txt_name" value="<?= set_value('txt_name'); ?>" class="form-control" placeholder="Enter name"> </div> <div class="form-group"> <label for="txt_subject">Subject</label> <?= form_error('txt_subject'); ?> <input type="text" name="txt_subject" value="<?= set_value('txt_subject'); ?>" class="form-control" placeholder="Enter subject"> </div> <div class="form-group"> <label for="txt_message">Your message</label> <?= form_error('txt_message'); ?> <textarea name="txt_message" class="form-control" rows="3" placeholder="Enter message"><?= set_value('txt_message'); ?></textarea> </div> <button type="submit" class="btn btn-lg btn-red">Send Message</button> <?= form_close(); ?> </div> <div class="col-sm-4"> <h3 class="headline second-child"><span>Our Address</span></h3> <p> Address 1: 407a Hau Giang, District 6, HCMC, Viet Nam<br /> Address 2: 4/4 Xuan Thoi Dong 2, Xuan Thoi Dong, HCMC, Viet Nam<br /> Phone: (+84)1652 175 179<br /> Email: <?= mailto('techstormteamwork@gmail.com', 'techstormteamwork@gmail.com') ?> </p> <h3 class="headline"><span>Map</span></h3> <div class="google-maps" id="map"></div> <script src="https://maps.googleapis.com/maps/api/js?v=3.exp"></script> <script type="text/javascript"> var map; function initialize() { var myLatlng = new google.maps.LatLng(10.873141, 106.591801); var mapOptions = { zoom: 15, center: myLatlng }; var map = new google.maps.Map(document.getElementById('map'), mapOptions); var marker = new google.maps.Marker({ position: myLatlng, map: map, title: 'TechStorm!' }); } google.maps.event.addDomListener(window, 'load', initialize); </script> </div> </div> <!-- / .row --> </div> <!-- / .container -->
00-techstorm
trunk/application/views/home/contact.php
PHP
gpl3
3,630
<!-- Home Slider --> <div class="home-slider"> <!-- Carousel --> <div id="home-slider" class="carousel slide" data-ride="carousel"> <!-- Indicators --> <ol class="carousel-indicators"> <li data-target="#home-slider" data-slide-to="0" class="active"></li> <li data-target="#home-slider" data-slide-to="1"></li> <li data-target="#home-slider" data-slide-to="2"></li> </ol> <!-- Wrapper for slides --> <div class="carousel-inner"> <!-- Slide #1 --> <div class="item active" id="item-1"> <div class="container"> <div class="row"> <div class="col-sm-6"> <h1 class="first-child animated slideInDown delay-2">TechStorm Solution</h1> <h3 class="animated slideInDown delay-3">Fly you to success</h3> <p class="text-muted animated slideInLeft delay-4">“Very hard working and very professional guy in their field. I am very happy with his work and recommend him to my other friends, and really want to hire again and again. I give him full marks 100/100.” - Khan1964 <span class="pakistan" data-toggle="tooltip" data-placement="top" title="Pakistan"></span></p> <?= anchor('home/about', 'More Information', array('class' => 'btn btn-lg btn-blue animated fadeInUpBig delay-5', 'target' => '_blank')) ?> <?= anchor('home/contact', 'Contact Us Now!', array('class' => 'btn btn-lg btn-red animated fadeInUpBig delay-5', 'target' => '_blank')) ?> </div> <div class="col-sm-6 hidden-xs"> <img class="img-responsive" src="<?= $path ?>/img/showcase.png" alt="showcase"> </div> </div> <!-- / .row --> </div> <!-- / .container --> </div> <!-- / .item --> <!-- Slide #2 --> <div class="item" id="item-2"> <div class="container"> <div class="row"> <div class="col-sm-6"> <ul class="lead"> <li class="animated slideInLeft delay-2"><span>Professional services</span></li> <li class="animated slideInLeft delay-3"><span>Develope webites out of the box</span></li> <li class="animated slideInLeft delay-4"><span>Increase productivity of Ecommerce Website</span></li> <li class="animated slideInLeft delay-5"><span>User-Friendly design</span></li> </ul> <ul class="lead string"> <li class="animated fadeInUpBig delay-6"><span>Hard working with creative ideas</span></li> <li class="animated fadeInUpBig delay-7"><span>Quality is always the most important thing to us</span></li> </ul> </div> <div class="col-sm-6 hidden-xs"> <img class="img-responsive" src="<?= $path ?>/img/macbook.png" alt="..."> </div> </div> <!-- / .row --> </div> <!-- / .container --> </div> <!-- / .item --> <!-- Slide #3 --> <div class="item" id="item-3"> <div class="container"> <div class="row"> <div class="col-sm-6"> <h1 class="first-child animated slideInDown delay-2">"Fly you to success"</h1> <h3 class="animated slideInDown delay-3">It's our target when we work for you</h3> <ul> <li class="animated slideInLeft delay-4"><i class="fa fa-chevron-circle-right fa-fw"></i> Discuss about requirement.</li> <li class="animated slideInLeft delay-5"><i class="fa fa-chevron-circle-right fa-fw"></i> Finding the solution for project.</li> <li class="animated slideInLeft delay-6"><i class="fa fa-chevron-circle-right fa-fw"></i> Hard working to complete the project with your satisfaction.</li> <li class="animated slideInLeft delay-7"><i class="fa fa-chevron-circle-right fa-fw"></i> Give support time when completed your project.</li> </ul> <?= anchor('home/contact', 'Contact us now!', array('class' => 'btn btn-lg btn-red animated fadeInUpBig delay-8', 'target' => '_blank')) ?> </div> <div class="col-sm-6 hidden-xs"> <img class="img-responsive" src="<?= $path ?>/img/iphone.png" alt="..."> </div> </div> <!-- / .row --> </div> <!-- / .container --> </div> <!-- / .item --> </div> <!-- / .carousel --> <!-- Controls --> <a class="carousel-arrow carousel-arrow-prev" href="#home-slider" data-slide="prev"> <i class="fa fa-angle-left"></i> </a> <a class="carousel-arrow carousel-arrow-next" href="#home-slider" data-slide="next"> <i class="fa fa-angle-right"></i> </a> </div> </div> <!-- / .home-slider --> <!-- Services --> <div class="home-services"> <div class="container"> <div class="row"> <div class="col-sm-12 col-md-7"> <ul> <li> <i class="fa fa-gears"></i> <p><span>Professional </span> Services</p> </li> <li> <i class="fa fa-flash"></i> <p>Creative <span>Ideas</span></p> </li> <li> <i class="fa fa-heart"></i> <p><span>Work With Our</span> Passion!</p> </li> <li> <i class="fa fa-globe"></i> <p><span>Global</span> Clients</p> </li> </ul> </div> <div class="col-md-5 hidden-sm hidden-xs"> <p class="lead">"TechStorm - Fly you to success"</p> </div> </div> <!-- / .row --> </div> <!-- / .container --> </div> <!-- / .services --> <!-- Browser Showcase --> <div class="container"> <div class="row"> <div class="col-sm-12"> <h2 class="first-child text-center">Provide you with beautiful website designs</h2> <h4 class="text-blue text-center">Perfect to start your bussiness.</h4> <div class="browser-showcase"> <img src="<?= $path ?>/img/browsers.png" class="img-responsive" alt="..."> </div> </div> </div> <!-- / .row --> </div> <!-- / .container --> <!-- Main Services --> <div class="main-services"> <div class="container"> <div class="row"> <div class="col-sm-4"> <div class="services"> <div class="service-item"> <i class="fa fa-home"></i> <div class="service-desc"> <h4>Web Development</h4> <p>With more than 4 years experiences in Web Development, we can build amazing websites with the best interaction and a smoothly functionalities for you. We always apply newest technologies on our products such as HTML5, ASP.NET, PHP, Java,...</p> </div> </div> </div> <!-- / .services --> </div> <div class="col-sm-4"> <div class="services"> <div class="service-item"> <i class="fa fa-mobile"></i> <div class="service-desc"> <h4>Mobile Development</h4> <p>If you want to create an Android, IPhone or Windows Phone apps, we are your best choices. We can integrate the apps with Google Maps, Chat Box, Facebook/Twitter/Google logins,... </p> </div> </div> </div> <!-- / .services --> </div> <div class="col-sm-4"> <div class="services"> <div class="service-item"> <i class="fa fa-facebook"></i> <div class="service-desc"> <h4>Integrate Facebook, Social Networks</h4> <p>We can integrate social networks for your website. With social networks integration, user will easy to access your website.</p> </div> </div> </div> <!-- / .services --> </div> </div> <div class="row"> <div class="col-sm-4"> <div class="services"> <div class="service-item"> <i class="fa fa-money"></i> <div class="service-desc"> <h4>Payment Gateway</h4> <p>Don't worry about how can user pay for your products, let us make the payment gateway for your website. Some of popular gateway: Paypal, Skrill, Visa, Master, 2Checkout,....</p> </div> </div> </div> <!-- / .services --> </div> <div class="col-sm-4"> <div class="services"> <div class="service-item"> <i class="fa fa-envelope"></i> <div class="service-desc"> <h4>Our Support</h4> <p>We can give you the best support for your projects through Skype or Email.</p> </div> </div> </div> <!-- / .services --> </div> <div class="col-sm-4"> <div class="services"> <div class="service-item"> <i class="fa fa-rocket"></i> <div class="service-desc"> <h4>Hard Working</h4> <p>When on your project, you will be sure satisfied with our work.</p> </div> </div> </div> <!-- / .services --> </div> </div> <!-- / .row --> </div> <!-- / .container --> </div> <!-- / .main-features --> <!-- Feedback --> <div class="feedbacks"> <div class="container"> <div class="row"> <div class="col-sm-12"> <h2 class="text-center">What Clients Say About Us</h2> </div> </div> <!-- / .row --> <div class="row"> <div class="col-sm-6 col-md-4"> <div class="feedback"> <div class="nickname"> <i class="fa fa-user fa-2x"></i> <div class="clear"></div> janvnbs <div class="netherlands" data-toggle="tooltip" data-placement="top" title="Netherlands"></div> </div> <div> <p> “I am very happy with my project, no problems at all with this freelancer!” </p> </div> </div> </div> <div class="col-sm-6 col-md-4"> <div class="feedback"> <div class="nickname"> <i class="fa fa-user fa-2x"></i> <div class="clear"></div> ibrahim1406 <div class="united-states" data-toggle="tooltip" data-placement="top" title="United States"></div> </div> <div> <p> “He is really great person and work hard to finish my work. also, he is very helpful. I recommended people to work with him” </p> </div> </div> </div> <div class="hidden-sm col-md-4"> <div class="feedback"> <div class="nickname"> <i class="fa fa-user fa-2x"></i> <div class="clear"></div> MeI12 <div class="israel" data-toggle="tooltip" data-placement="top" title="Israel"></div> </div> <div> <p> “beautiful work, completed even before the scheduled time.great freelancer to hire :)” </p> </div> </div> </div> <div class="col-sm-6 col-md-6"> <div class="feedback"> <div class="nickname"> <i class="fa fa-user fa-2x"></i> <div class="clear"></div> Khan1964 <div class="pakistan" data-toggle="tooltip" data-placement="top" title="Pakistan"></div> </div> <div> <p> “Very hard working and very professional guy in their field. I am very happy with his work and recommend him to my other friends, and really want to hire again and again. I give him full marks 100/100.” </p> </div> </div> </div> <div class="col-sm-6 col-md-6"> <div class="feedback"> <div class="nickname"> <i class="fa fa-user fa-2x"></i> <div class="clear"></div> rubinse <div class="france" data-toggle="tooltip" data-placement="top" title="France"></div> </div> <div> <p> “He is very good and honest, also, he is very professional on his work I will work with .” </p> </div> </div> </div> </div> <!-- / .row --> </div> <!-- / .container --> </div> <!-- / .feedback --> <div class="container"> <div class="row"> <div class="col-sm-12"> <?= img($path . '/img/banner-ts.png'); ?> </div> </div> <!-- / .row --> </div>
00-techstorm
trunk/application/views/home/index.php
PHP
gpl3
14,909
<div class="topic"> <div class="container"> <div class="row"> <div class="col-sm-4"> <h3><?= $title ?></h3> </div> <div class="col-sm-8"> <ol class="breadcrumb pull-right hidden-xs"> <li><?= anchor('home/index', 'Home'); ?></li> <li class="active"><?= $title ?></li> </ol> </div> </div> </div> </div> <div class="container"> <div class="row"> <div class="col-sm-8"> <h3 class="headline first-child"><span>Successfull!</span></h3> <p>You sent your message to us successfully, we'll reply to you soon.</p> <?= anchor('home/contact', 'Go Back'); ?> </div> <div class="col-sm-4"> <h3 class="headline second-child"><span>Our Address</span></h3> <p> Address 1: 407a Hau Giang, District 6, HCMC, Viet Nam<br /> Address 2: 4/4 Xuan Thoi Dong 2, Xuan Thoi Dong, HCMC, Viet Nam<br /> Phone: (+84)1652 175 179<br /> Email: <?= mailto('techstormteamwork@gmail.com', 'techstormteamwork@gmail.com') ?> </p> <h3 class="headline"><span>Map</span></h3> <div class="google-maps" id="map"></div> <script src="https://maps.googleapis.com/maps/api/js?v=3.exp"></script> <script type="text/javascript"> var map; function initialize() { var myLatlng = new google.maps.LatLng(10.873141, 106.591801); var mapOptions = { zoom: 15, center: myLatlng }; var map = new google.maps.Map(document.getElementById('map'), mapOptions); var marker = new google.maps.Marker({ position: myLatlng, map: map, title: 'TechStorm!' }); } google.maps.event.addDomListener(window, 'load', initialize); </script> </div> </div> <!-- / .row --> </div> <!-- / .container -->
00-techstorm
trunk/application/views/home/contact_success.php
PHP
gpl3
2,229
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
00-techstorm
trunk/application/views/index.html
HTML
gpl3
114
asd
00-techstorm
trunk/application/views/admin/dashboard/index.php
Hack
gpl3
3
<?= link_tag('assets/isotope/css/style.css'); ?> <div class="topic"> <div class="container"> <div class="row"> <div class="col-sm-4"> <h3>Portfolio</h3> </div> <div class="col-sm-8"> <ol class="breadcrumb pull-right hidden-xs"> <li> <?= anchor('home/index', 'Home') ?> </li> <li class="active">Portfolio</li> </ol> </div> </div> </div> </div> <!-- Content --> <div class="container"> <div class="row"> <div class="col-sm-3"> <!-- Categories --> <div class="panel panel-default"> <div class="panel-heading"> Portfolio Category </div> <div class="panel-body"> <ul id="filters"> <li><a href="#" data-filter="*">All</a></li> <?php foreach ($cat_array as $cat) : ?> <li><a href="#" data-filter=".cat<?= $cat['id'] ?>"><?= $cat['name'] ?></a></li> <?php endforeach; ?> </ul> </div> </div> </div> <div class="col-sm-9"> <div class="row" id="isotope-container"> <?php foreach ($por_array as $por) : ?> <div class="col-sm-6 col-md-6 col-lg-4 isotope-item<?php foreach ($por['category'] as $por_cat) : echo ' cat' . $por_cat['por_cat_id']; endforeach; ?>"> <div class="portfolio-item"> <div class="portfolio-thumbnail"> <?php if (!empty($por['img'])) : ?> <img class="img-responsive" src="<?= $por_img_path . $por['img'][0]['img_url'] ?>" alt="<?= $por['slug'] ?>"> <?php else : ?> <img class="img-responsive" src="<?= $por_img_path . 'logo.png' ?>" alt="<?= $por['slug'] ?>"> <?php endif; ?> <div class="mask"> <p> <?php if (!empty($por['img'])) : ?> <a href="<?= $por_img_path . $por['img'][0]['img_url'] ?>" data-lightbox="template_showcase"><i class="fa fa-search-plus fa-2x"></i></a> <?php else : ?> <a href="<?= $por_img_path . 'logo.png' ?>" data-lightbox="template_showcase"><i class="fa fa-search-plus fa-2x"></i></a> <?php endif; ?> <?= anchor('portfolio/detail/' . $por['slug'], '<i class="fa fa-info-circle fa-2x"></i>') ?> </p> </div> </div> </div> <!--.portfolio-item--> </div> <?php endforeach; ?> </div> </div> </div> <!-- / .row --> </div> <!-- / .container --> <!-- Script --> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script> <script type="text/javascript" src="<?= $path ?>/isotope/js/isotope.min.js"></script> <script type="text/javascript" src="<?= $path ?>/js/portfolio.js"></script>
00-techstorm
trunk/application/views/portfolio/index.php
PHP
gpl3
3,667
<div class="topic"> <div class="container"> <div class="row"> <div class="col-sm-4"> <h3><?= $title ?></h3> </div> <div class="col-sm-8"> <ol class="breadcrumb pull-right hidden-xs"> <li><?= anchor('home/index', 'Home') ?></li> <li><?= anchor('portfolio/index', 'Portfolio') ?></li> <li class="active"><?= $title ?></li> </ol> </div> </div> </div> </div> <!--?= var_dump($latest_portfolio); ?--> <!--?= var_dump($item); ?--> <div class="container"> <div class="row"> <div class="col-sm-6"> <div class="portfolio-slideshow"> <!-- Image Carousel --> <div id="portfolio-slideshow" class="carousel slide" data-ride="carousel"> <!-- Indicators --> <ol class="carousel-indicators"> <?php if (empty($item['img'])) : ?> <li data-target="#portfolio-slideshow" data-slide-to="0" class="active"></li> <?php else : $i = 0; foreach ($item['img'] as $por_img) : ?> <li data-target="#portfolio-slideshow" data-slide-to="<?= $i ?>"></li> <?php $i++; endforeach; endif; ?> </ol> <!-- Wrapper for slides --> <div class="carousel-inner"> <?php if (empty($item['img'])) : ?> <div class="item active"> <img src="<?= $por_img_path . 'logo.png' ?>" alt="default"> </div> <?php else : $i = 0; foreach ($item['img'] as $item_img) : if ($i === 0) : echo '<div class="item active">'; else : echo '<div class="item">'; endif; ?> <img src="<?= $por_img_path . $item_img['img_url'] ?>" alt="default"> </div> <?php $i++; endforeach; endif; ?> </div> <!-- Controls --> <a class="carousel-arrow carousel-arrow-prev" href="#portfolio-slideshow" data-slide="prev"> <i class="fa fa-angle-left"></i> </a> <a class="carousel-arrow carousel-arrow-next" href="#portfolio-slideshow" data-slide="next"> <i class="fa fa-angle-right"></i> </a> </div> </div> </div> <div class="col-sm-6"> <h3 class="headline second-child"><span><?= $item['title']; ?></span></h3> <p><?= $item['description']; ?></p> <br /> <h4 class="headline"><span>Portfolio Info</span></h4> <table class="table"> <tr> <td>Completion Time<td> <td><?= $item['completion_time'] . ' days' ?></td> </tr> <tr> <td>Quality of Work<td> <td style="color: #dd4b39"> <?php $quality_of_work = $item['quality_of_work']; for ($i = 0; $i < 5; $i++) { if ($quality_of_work >= 1) { echo '<i class="fa fa-star"></i>'; } elseif ($quality_of_work < 1 && $quality_of_work > 0) { echo '<i class="fa fa-star-half-full"></i>'; } else { echo '<i class="fa fa-star-o"></i>'; } $quality_of_work--; } ?> </td> </tr> <tr> <td>Communication<td> <td style="color: #dd4b39"> <?php $communication = $item['communication']; for ($i = 0; $i < 5; $i++) { if ($communication >= 1) { echo '<i class="fa fa-star"></i>'; } elseif ($communication < 1 && $communication > 0) { echo '<i class="fa fa-star-half-full"></i>'; } else { echo '<i class="fa fa-star-o"></i>'; } $communication--; } ?> </td> </tr> <tr> <td>Expertise<td> <td style="color: #dd4b39"> <?php $expertise = $item['expertise']; for ($i = 0; $i < 5; $i++) { if ($expertise >= 1) { echo '<i class="fa fa-star"></i>'; } elseif ($expertise < 1 && $expertise > 0) { echo '<i class="fa fa-star-half-full"></i>'; } else { echo '<i class="fa fa-star-o"></i>'; } $expertise--; } ?> </td> </tr> <tr> <td>Professionalism<td> <td style="color: #dd4b39"> <?php $professionalism = $item['professionalism']; for ($i = 0; $i < 5; $i++) { if ($professionalism >= 1) { echo '<i class="fa fa-star"></i>'; } elseif ($professionalism < 1 && $professionalism > 0) { echo '<i class="fa fa-star-half-full"></i>'; } else { echo '<i class="fa fa-star-o"></i>'; } $professionalism--; } ?> </td> </tr> <tr> <td>Would Hire Again<td> <td style="color: #dd4b39"> <?php $would_hire_again = $item['would_hire_again']; for ($i = 0; $i < 5; $i++) { if ($would_hire_again >= 1) { echo '<i class="fa fa-star"></i>'; } elseif ($would_hire_again < 1 && $would_hire_again > 0) { echo '<i class="fa fa-star-half-full"></i>'; } else { echo '<i class="fa fa-star-o"></i>'; } $would_hire_again--; } ?> </td> </tr> <tr> <td>Feedback<td> <td><kbd><?= ucfirst($item['feedback']); ?></kbd></td> </tr> </table> </div> </div> <!-- / .row --> <div class="row"> <div class="col-sm-12"> <h3 class="headline"><span>Latest Works</span></h3> </div> <?php foreach ($latest_portfolio as $latest_item) : ?> <div class="col-sm-3"> <div class="portfolio-item"> <div class="portfolio-thumbnail"> <?php if (empty($latest_item['img'])) { $img_path = $por_img_path . 'logo.png'; } else { $img_path = $por_img_path . $latest_item['img'][0]['img_url']; } ?> <img class="img-responsive" src="<?= $img_path ?>" alt="<?= $latest_item['title'] ?>"> <div class="mask"> <p> <a href="<?= $img_path; ?>" data-lightbox="template_showcase"><i class="fa fa-search-plus fa-2x"></i></a> <?= anchor('portfolio/detail/' . $latest_item['slug'], '<i class="fa fa-info-circle fa-2x"></i>') ?> </p> </div> </div> </div> <!-- / .portfolio-item --> </div> <?php endforeach; ?> </div> <!-- / .row --> </div> <!-- / .container -->
00-techstorm
trunk/application/views/portfolio/detail.php
PHP
gpl3
8,812
</div> </div> <footer> <hr> <p class="pull-right">Design by <a href="http://www.techstorm-solution.com" target="_blank">TechStorm</a></p> <p>&copy; 2014 <a href="#">TechStorm</a></p> </footer> </div> <script src="<?= $path ?>/lib/bootstrap3/dist/js/bootstrap.js"></script> <script type="text/javascript"> $("[rel=tooltip]").tooltip({animation: false}); $(function() { $('.demo-cancel-click').click(function() { return false; }); }); </script> </body> </html>
00-techstorm
trunk/application/views/include/admin/footer.php
PHP
gpl3
513
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <title><?= $title; ?></title> <meta content="IE=edge,chrome=1" http-equiv="X-UA-Compatible"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta name="description" content="admin panel"> <meta name="author" content="techstorm"> <!-- For sample logo only--> <!--Remove if you no longer need this font--> <link rel="stylesheet" type="text/css" href="http://fonts.googleapis.com/css?family=Aguafina+Script"> <!--For sample logo only--> <link rel="stylesheet" type="text/css" href="<?= $path ?>/lib/bootstrap3/dist/css/bootstrap.css"> <link rel="stylesheet" href="<?= $path ?>/lib/FontAwesome/css/font-awesome.css"> <script src="<?= $path ?>/lib/jquery-1.7.2.min.js" type="text/javascript"></script> <script src="<?= $path ?>/javascripts/site.js" type="text/javascript"></script> <link rel="stylesheet" type="text/css" href="<?= $path ?>/stylesheets/theme.css"> <!-- Le HTML5 shim, for IE6-8 support of HTML5 elements --> <!--[if lt IE 9]> <script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script> <![endif]--> <!-- Le fav and touch icons --> <link rel="shortcut icon" href="<?= base_url() . 'assets/img/logo.png' ?>"> </head> <!--[if lt IE 7 ]> <body class="ie ie6"> <![endif]--> <!--[if IE 7 ]> <body class="ie ie7 "> <![endif]--> <!--[if IE 8 ]> <body class="ie ie8 "> <![endif]--> <!--[if IE 9 ]> <body class="ie ie9 "> <![endif]--> <!--[if (gt IE 9)|!(IE)]><!--> <body class=""> <!--<![endif]--> <div class="navbar navbar-inverse navbar-fixed-top"> <div class="navbar-header"> <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse"> <span class="icon-reorder"></span> </button> <!--<a class="navbar-brand" href="index.html">TechStorm.</a>--> <?php $img = array( 'src' => base_url() . 'assets/img/logo.png', 'alt' => 'logo' ); echo anchor('admin/dashboard/index', img($img), array('id' => 'logo', 'class' => 'navbar-brand')); ?> </div> <div class="hidden-xs"> <ul class="nav navbar-nav pull-right"> <li class="hidden-phone"><a href="#" role="button">Settings</a></li> <li id="fat-menu" class="dropdown"> <a href="#" role="button" class="dropdown-toggle" data-toggle="dropdown"> <i class="icon-user"></i> Jack Smith <i class="icon-caret-down"></i> </a> <ul class="dropdown-menu"> <li><a tabindex="-1" href="#">My Account</a></li> <li class="divider"></li> <li><a tabindex="-1" class="visible-phone" href="#">Settings</a></li> <li class="divider visible-phone"></li> <li><a tabindex="-1" href="sign-in.html">Logout</a></li> </ul> </li> </ul> </div><!--/.navbar-collapse --> </div> <div class="navbar-collapse collapse"> <div id="main-menu"> <div id="phone-navigation" class="visible-xs"> <ul id="dashboard-menu" class="nav nav-list"> <li class="active "><a rel="tooltip" data-placement="right" data-original-title="Dashboard" href="index.html"><i class="icon-home"></i> <span class="caption">Dashboard</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Reports" href="reports.html"><i class="icon-bar-chart"></i> <span class="caption">Reports</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="UI Features" href="components.html"><i class="icon-briefcase"></i> <span class="caption">UI Features</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Pricing" href="pricing.html"><i class="icon-magic"></i> <span class="caption">Pricing</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Media" href="media.html"><i class="icon-film"></i> <span class="caption">Media</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Blog" href="blog.html"><i class="icon-beaker"></i> <span class="caption">Blog</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Blog Entry" href="blog-item.html"><i class="icon-coffee"></i> <span class="caption">Blog Entry</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Help" href="help.html"><i class="icon-question-sign"></i> <span class="caption">Help</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Faq" href="faq.html"><i class="icon-book"></i> <span class="caption">Faq</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Calendar" href="calendar.html"><i class="icon-calendar"></i> <span class="caption">Calendar</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Forms" href="forms.html"><i class="icon-tasks"></i> <span class="caption">Forms</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Tables" href="tables.html"><i class="icon-table"></i> <span class="caption">Tables</span></a></li> <li class=" theme-mobile-hack hidden-xs"><a rel="tooltip" data-placement="right" data-original-title="Mobile" href="mobile.html"><i class="icon-comment-alt"></i> <span class="caption">Mobile</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Icons" href="icons.html"><i class="icon-heart"></i> <span class="caption">Icons</span></a></li> </ul> </div> <ul class="nav nav-tabs hidden-xs"> <li class="active"><a href="index.html"><i class="icon-dashboard"></i> <span>Dashboard</span></a></li> <li ><a href="reports.html" ><i class="icon-bar-chart"></i> <span>Reports</span></a></li> <li ><a href="components.html" ><i class="icon-cogs"></i> <span>Components</span></a></li> <li ><a href="pricing.html"><i class="icon-magic"></i> <span>Pricing</span></a></li> <li class="dropdown"> <a href="#" class="dropdown-toggle" data-toggle="dropdown"><i class="icon-cog"></i> Settings <b class="caret"></b></a> <ul class="dropdown-menu"> <li><a href="sign-in.html"><span>Sign-in Page</span></a></li> <li><a href="sign-up.html"><span>Sign-up Page</span></a></li> <li><a href="reset-password.html"><span>Forgot Password Page</span></a></li> </ul> </li> </ul> </div> </div> <div id="sidebar-nav" class="hidden-xs"> <ul id="dashboard-menu" class="nav nav-list"> <li class="active "><a rel="tooltip" data-placement="right" data-original-title="Dashboard" href="index.html"><i class="icon-home"></i> <span class="caption">Dashboard</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Reports" href="reports.html"><i class="icon-bar-chart"></i> <span class="caption">Reports</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="UI Features" href="components.html"><i class="icon-briefcase"></i> <span class="caption">UI Features</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Pricing" href="pricing.html"><i class="icon-magic"></i> <span class="caption">Pricing</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Media" href="media.html"><i class="icon-film"></i> <span class="caption">Media</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Blog" href="blog.html"><i class="icon-beaker"></i> <span class="caption">Blog</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Blog Entry" href="blog-item.html"><i class="icon-coffee"></i> <span class="caption">Blog Entry</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Help" href="help.html"><i class="icon-question-sign"></i> <span class="caption">Help</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Faq" href="faq.html"><i class="icon-book"></i> <span class="caption">Faq</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Calendar" href="calendar.html"><i class="icon-calendar"></i> <span class="caption">Calendar</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Forms" href="forms.html"><i class="icon-tasks"></i> <span class="caption">Forms</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Tables" href="tables.html"><i class="icon-table"></i> <span class="caption">Tables</span></a></li> <li class=" theme-mobile-hack"><a rel="tooltip" data-placement="right" data-original-title="Mobile" href="mobile.html"><i class="icon-comment-alt"></i> <span class="caption">Mobile</span></a></li> <li class=" "><a rel="tooltip" data-placement="right" data-original-title="Icons" href="icons.html"><i class="icon-heart"></i> <span class="caption">Icons</span></a></li> </ul> </div> <div class="content"> <div class="row"> <div class="col-sm-8 main-content">
00-techstorm
trunk/application/views/include/admin/header.php
PHP
gpl3
10,695
</div> <!-- / .wrapper --> <!-- Footer --> <footer> <div class="container"> <div class="row"> <!-- Contact Us --> <div class="col-sm-6"> <h4><i class="fa fa-map-marker text-red"></i> Contact Us</h4> <p>Do not hesitate to contact us if you have any questions or feature requests:</p> <p> Address 1: 407a Hau Giang, W11, District 6, HCMC, Viet Nam<br /> Address 2: 4/4 Xuan Thoi Dong 2, Xuan Thoi Dong, HCMC, Viet Nam<br/> Phone: (+84)1652 175 179<br /> Email: <?= mailto('techstormteamwork@gmail.com', 'techstormteamwork@gmail.com') ?> </p> </div> <!-- Newsletter --> <div class="col-sm-6"> <h4><i class="fa fa-envelope text-red"></i> Newsletter</h4> <p> Enter your e-mail below to subscribe to our free newsletter. <br> We promise not to bother you often! </p> <form class="form" role="form"> <div class="row"> <div class="col-sm-8"> <div class="input-group"> <label class="sr-only" for="subscribe-email">Email address</label> <input type="email" class="form-control" id="subscribe-email" placeholder="Enter your email"> <span class="input-group-btn"> <button type="submit" class="btn btn-default">OK</button> </span> </div> </div> </div> </form> </div> </div> </div> </footer> <!-- Copyright --> <div class="container"> <div class="row"> <div class="col-sm-12"> <div class="copyright"> Copyright 2014 &copy; - TechStorm Solution.</a> | All Rights Reserved </div> </div> </div> <!-- / .row --> </div> <!-- / .container --> <!-- Bootstrap core JavaScript ================================================== --> <!-- Placed at the end of the document so the pages load faster --> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script> <script src="<?= $path ?>/js/bootstrap.min.js"></script> <script src="<?= $path ?>/js/scrolltopcontrol.js"></script> <script src="<?= $path ?>/js/lightbox-2.6.min.js"></script> <script src="<?= $path ?>/js/custom.js"></script> <script src="<?= $path ?>/js/index.js"></script> </body> </html>
00-techstorm
trunk/application/views/include/footer.php
PHP
gpl3
2,716
<?php $this->load->helper('html'); $active = array( 'home/index' => '', 'home/about' => '', 'home/contact' => '', 'portfolio/index' => '', ); $active[$this->uri->uri_string()] = 'active'; ?> <!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <!--<meta http-equiv="X-UA-Compatible" content="IE=edge">--> <meta name="viewport" content="width=device-width, initial-scale=1"> <meta name="description" content=""> <meta name="author" content=""> <link rel="shortcut icon" href="<?= $path ?>/img/logo.png"> <title><?= $title; ?></title> <!-- Bootstrap core CSS --> <!--<link href="css/bootstrap.min.css" rel="stylesheet">--> <!-- Custom styles for this template --> <link href="<?= $path ?>/css/style.css" rel="stylesheet"> <!-- Resources --> <link href="<?= $path ?>/fonts/font-awesome-4.0.3/css/font-awesome.min.css" rel="stylesheet"> <link href="<?= $path ?>/css/animate.css" rel="stylesheet"> <link href="<?= $path ?>/css/lightbox.css" rel="stylesheet"> <link href='http://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,600,700' rel='stylesheet' type='text/css'> <link href='http://fonts.googleapis.com/css?family=Ubuntu:300,400,500,700' rel='stylesheet' type='text/css'> <!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries --> <!--[if lt IE 9]> <script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script> <script src="https://oss.maxcdn.com/libs/respond.js/1.4.2/respond.min.js"></script> <![endif]--> </head> <body> <!-- Navigation --> <div class="navbar navbar-default navbar-fixed-top" role="navigation"> <div class="container"> <div class="navbar-header"> <button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse"> <span class="sr-only">Toggle navigation</span> <span class="icon-bar"></span> <span class="icon-bar"></span> <span class="icon-bar"></span> </button> <?php $img = array( 'src' => $path . '/img/logo.png', 'alt' => 'logo' ); echo anchor('home/index', img($img), array('id' => 'logo', 'class' => 'navbar-brand')); ?> </div> <div class="collapse navbar-collapse"> <ul id="menu" class="nav navbar-nav navbar-right"> <li class="<?= $active['home/index']; ?>"> <?= anchor('home/index', 'Home'); ?> </li> <li class="<?= $active['portfolio/index']; ?>"> <?= anchor('portfolio/index', 'Portfolio'); ?> </li> <li class="<?= $active['home/about']; ?>"> <?= anchor('home/about', 'About Us'); ?> </li> <li class="<?= $active['home/contact']; ?>"> <?= anchor('home/contact', 'Contact'); ?> </li> </ul> <!-- Mobile Search --> <form class="navbar-form navbar-right visible-xs" role="search"> <div class="input-group"> <input type="text" class="form-control" placeholder="Search"> <span class="input-group-btn"> <button class="btn btn-red" type="button">Search!</button> </span> </div> </form> </div><!--/.nav-collapse --> </div> </div> <!-- / .navigation --> <!-- Wrapper --> <div class="wrapper">
00-techstorm
trunk/application/views/include/header.php
PHP
gpl3
4,105
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
00-techstorm
trunk/application/errors/index.html
HTML
gpl3
114
<!DOCTYPE html> <html lang="en"> <head> <title>Error</title> <style type="text/css"> ::selection{ background-color: #E13300; color: white; } ::moz-selection{ background-color: #E13300; color: white; } ::webkit-selection{ background-color: #E13300; color: white; } body { background-color: #fff; margin: 40px; font: 13px/20px normal Helvetica, Arial, sans-serif; color: #4F5155; } a { color: #003399; background-color: transparent; font-weight: normal; } h1 { color: #444; background-color: transparent; border-bottom: 1px solid #D0D0D0; font-size: 19px; font-weight: normal; margin: 0 0 14px 0; padding: 14px 15px 10px 15px; } code { font-family: Consolas, Monaco, Courier New, Courier, monospace; font-size: 12px; background-color: #f9f9f9; border: 1px solid #D0D0D0; color: #002166; display: block; margin: 14px 0 14px 0; padding: 12px 10px 12px 10px; } #container { margin: 10px; border: 1px solid #D0D0D0; -webkit-box-shadow: 0 0 8px #D0D0D0; } p { margin: 12px 15px 12px 15px; } </style> </head> <body> <div id="container"> <h1><?php echo $heading; ?></h1> <?php echo $message; ?> </div> </body> </html>
00-techstorm
trunk/application/errors/error_general.php
PHP
gpl3
1,147
<div style="border:1px solid #990000;padding-left:20px;margin:0 0 10px 0;"> <h4>A PHP Error was encountered</h4> <p>Severity: <?php echo $severity; ?></p> <p>Message: <?php echo $message; ?></p> <p>Filename: <?php echo $filepath; ?></p> <p>Line Number: <?php echo $line; ?></p> </div>
00-techstorm
trunk/application/errors/error_php.php
PHP
gpl3
288
<!DOCTYPE html> <html lang="en"> <head> <title>Database Error</title> <style type="text/css"> ::selection{ background-color: #E13300; color: white; } ::moz-selection{ background-color: #E13300; color: white; } ::webkit-selection{ background-color: #E13300; color: white; } body { background-color: #fff; margin: 40px; font: 13px/20px normal Helvetica, Arial, sans-serif; color: #4F5155; } a { color: #003399; background-color: transparent; font-weight: normal; } h1 { color: #444; background-color: transparent; border-bottom: 1px solid #D0D0D0; font-size: 19px; font-weight: normal; margin: 0 0 14px 0; padding: 14px 15px 10px 15px; } code { font-family: Consolas, Monaco, Courier New, Courier, monospace; font-size: 12px; background-color: #f9f9f9; border: 1px solid #D0D0D0; color: #002166; display: block; margin: 14px 0 14px 0; padding: 12px 10px 12px 10px; } #container { margin: 10px; border: 1px solid #D0D0D0; -webkit-box-shadow: 0 0 8px #D0D0D0; } p { margin: 12px 15px 12px 15px; } </style> </head> <body> <div id="container"> <h1><?php echo $heading; ?></h1> <?php echo $message; ?> </div> </body> </html>
00-techstorm
trunk/application/errors/error_db.php
PHP
gpl3
1,156
<!DOCTYPE html> <html lang="en"> <head> <title>404 Page Not Found</title> <style type="text/css"> ::selection{ background-color: #E13300; color: white; } ::moz-selection{ background-color: #E13300; color: white; } ::webkit-selection{ background-color: #E13300; color: white; } body { background-color: #fff; margin: 40px; font: 13px/20px normal Helvetica, Arial, sans-serif; color: #4F5155; } a { color: #003399; background-color: transparent; font-weight: normal; } h1 { color: #444; background-color: transparent; border-bottom: 1px solid #D0D0D0; font-size: 19px; font-weight: normal; margin: 0 0 14px 0; padding: 14px 15px 10px 15px; } code { font-family: Consolas, Monaco, Courier New, Courier, monospace; font-size: 12px; background-color: #f9f9f9; border: 1px solid #D0D0D0; color: #002166; display: block; margin: 14px 0 14px 0; padding: 12px 10px 12px 10px; } #container { margin: 10px; border: 1px solid #D0D0D0; -webkit-box-shadow: 0 0 8px #D0D0D0; } p { margin: 12px 15px 12px 15px; } </style> </head> <body> <div id="container"> <h1><?php echo $heading; ?></h1> <?php echo $message; ?> </div> </body> </html>
00-techstorm
trunk/application/errors/error_404.php
PHP
gpl3
1,160
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
00-techstorm
trunk/application/index.html
HTML
gpl3
114
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
00-techstorm
trunk/application/language/index.html
HTML
gpl3
114
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
00-techstorm
trunk/application/language/english/index.html
HTML
gpl3
114
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
00-techstorm
trunk/application/helpers/index.html
HTML
gpl3
114
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
00-techstorm
trunk/application/hooks/index.html
HTML
gpl3
114
<?php class Portfolio_model extends CI_Model { public function __construct() { parent::__construct(); } public function get_portfolio($slug = FALSE) { if ($slug === FALSE) { $query = $this->db->get('portfolio'); } else { $query = $this->db->get_where('portfolio', array('slug' => $slug)); } $por_array = $query->result_array(); $result = array(); foreach ($por_array as $por_item) { $por_cat = $this->get_por_cat($por_item['id']); $por_item['category'] = $por_cat; $por_img = $this->get_por_img($por_item['id']); $por_item['img'] = $por_img; array_push($result, $por_item); } // return $por_array; return $result; } public function get_latest_portfolio($quantity = FALSE) { if ($quantity === FALSE) { $quantity = 4; } $this->db->order_by('created_date', 'desc'); $this->db->limit($quantity); $query = $this->db->get('portfolio'); $pors = $query->result_array(); $result = array(); foreach ($pors as $por) { $por_cat = $this->get_por_cat($por['id']); $por['category'] = $por_cat; $por_img = $this->get_por_img($por['id']); $por['img'] = $por_img; array_push($result, $por); } return $result; } public function set_portfolio($data) { return $this->db->insert('message', $data); } /** * * @param object data = array('portfolio_id', 'img_url') * @return type */ public function set_por_img($data) { return $this->db->insert('por_img_relation', $data); } /** * * @param int $id * @return all img of that portfolio */ public function get_por_img($id) { $query = $this->db->get_where('por_img_relation', array('portfolio_id' => $id)); return $query->result_array(); } public function get_category() { $query = $this->db->get('portfolio_category'); return $query->result_array(); } public function get_por_cat($id) { $query = $this->db->get_where('por_cat_relation', array('portfolio_id' => $id)); return $query->result_array(); } public function set_por_cat($data) { return $this->db->insert('por_cat_relation', $data); } }
00-techstorm
trunk/application/models/portfolio_model.php
PHP
gpl3
2,441
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
00-techstorm
trunk/application/models/index.html
HTML
gpl3
114
<?php class Contact_model extends CI_Model { public function __construct() { parent::__construct(); } /** * * @param type $type * @param type $value * @return result of type & value (example: type = 'id', value = '1') */ public function get_message($type = FALSE, $value = FALSE) { if ($type === FALSE OR $value === FALSE) { $query = $this->db->get('message'); return $query->result_array(); } else { $query = $this->db->get_where('message', array($type => $value)); return $query->row_array(); } } // public function set_message() { // $data = array( // 'email' => $this->input->post('txt_email'), // 'name' => $this->input->post('txt_name'), // 'subject' => $this->input->post('txt_subject'), // 'message' => $this->input->post('txt_message'), // ); // $this->load->library('email'); // // //Send email to client // $this->email->from('techstormteamwork@gmail.com', 'TechStorm'); // $this->email->to($data['email']); // $this->email->subject('TechStorm - Fly you to success!'); // //Send notification email to admin // // return $this->db->insert('message', $data); // } public function set_message($data) { // $data = array( // 'email' => $this->input->post('txt_email'), // 'name' => $this->input->post('txt_name'), // 'subject' => $this->input->post('txt_subject'), // 'message' => $this->input->post('txt_message'), // ); $this->load->library('email'); //Send email to client $this->email->from('techstormteamwork@gmail.com', 'TechStorm'); $this->email->to($data['email']); $this->email->subject('TechStorm - Fly you to success!'); $this->email->message('You have sent an message to TechStorm website. We will reply to you soon :-)'); $this->email->send(); //Send notification email to admin return $this->db->insert('message', $data); } }
00-techstorm
trunk/application/models/contact_model.php
PHP
gpl3
2,130
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
00-techstorm
trunk/application/logs/index.html
HTML
gpl3
114
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
00-techstorm
trunk/application/libraries/index.html
HTML
gpl3
114
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
00-techstorm
trunk/application/core/index.html
HTML
gpl3
114
<?php if (!defined('BASEPATH')) exit('No direct script access allowed'); class Portfolio extends CI_Controller { public function __construct() { parent::__construct(); $this->load->helper('url'); $this->load->model('portfolio_model'); } public function index() { $data['title'] = 'Portfolio'; $data['path'] = base_url() . 'assets'; $data['por_img_path'] = base_url() . 'upload/images/portfolio/'; $data['por_array'] = $this->portfolio_model->get_portfolio(); $data['cat_array'] = $this->portfolio_model->get_category(); $this->load->view('include/header', $data); $this->load->view('portfolio/index', $data); $this->load->view('include/footer', $data); } public function detail($slug = FALSE) { if (empty($slug)) { redirect('portfolio/index'); } else { $item = $this->portfolio_model->get_portfolio($slug); $data['item'] = $item[0]; if (empty($data['item'])) { redirect('portfolio/index'); } $data['title'] = 'Portfolio Detail'; $data['path'] = base_url() . 'assets'; $data['por_img_path'] = base_url() . 'upload/images/portfolio/'; $data['latest_portfolio'] = $this->portfolio_model->get_latest_portfolio(4); $this->load->view('include/header', $data); $this->load->view('portfolio/detail', $data); $this->load->view('include/footer', $data); } } }
00-techstorm
trunk/application/controllers/portfolio.php
PHP
gpl3
1,558
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
00-techstorm
trunk/application/controllers/index.html
HTML
gpl3
114
<?php if (!defined('BASEPATH')) exit('No direct script access allowed'); class Dashboard extends CI_Controller { public function __construct() { parent::__construct(); $this->load->helper(array('url', 'html')); } public function index() { if ($this->session->userdata('user_array') === FALSE) { redirect('admin/dashboard/login'); } $data['title'] = 'Dashboard'; $data['path'] = base_url() . 'assets/admin'; $this->load->view('include/admin/header', $data); $this->load->view('admin/dashboard/index', $data); $this->load->view('include/admin/footer', $data); } public function login() { if ($this->session->userdata('user_array') !== FALSE) { redirect('admin/dashboard/index'); } $data['title'] = 'Admin Panel Login'; $data['path'] = base_url() . 'assets/admin'; $this->load->view('include/admin/header', $data); $this->load->view('admin/dashboard/index', $data); $this->load->view('include/admin/footer', $data); } } /* End of file dashboard.php */ /* Location: ./application/controllers/admin/dashboard.php */
00-techstorm
trunk/application/controllers/admin/dashboard.php
PHP
gpl3
1,199
<?php if (!defined('BASEPATH')) exit('No direct script access allowed'); class Home extends CI_Controller { /** * Index Page for this controller. * * Maps to the following URL * http://example.com/index.php/welcome * - or - * http://example.com/index.php/welcome/index * - or - * Since this controller is set as the default controller in * config/routes.php, it's displayed at http://example.com/ * * So any other public methods not prefixed with an underscore will * map to /index.php/welcome/<method_name> * @see http://codeigniter.com/user_guide/general/urls.html */ public function __construct() { parent::__construct(); $this->load->helper('url'); $this->load->model('contact_model'); } public function index() { $data['title'] = 'Home'; $data['path'] = base_url() . 'assets'; $this->load->view('include/header', $data); $this->load->view('home/index', $data); $this->load->view('include/footer', $data); } public function about() { $data['title'] = 'About Us'; $data['path'] = base_url() . 'assets'; $this->load->view('include/header', $data); $this->load->view('home/about', $data); $this->load->view('include/footer', $data); } public function contact() { $data['title'] = 'Contact'; $data['path'] = base_url() . 'assets'; $this->load->helper('form'); $this->load->library('form_validation'); $this->load->database(); $this->load->view('include/header', $data); $this->load->view('home/contact', $data); $this->load->view('include/footer', $data); } public function send_message() { $data['title'] = 'Contact'; $data['path'] = base_url() . 'assets'; //Load helpers $this->load->helper(array('form', 'date')); $this->load->library('form_validation'); //Set tag wrap the error message $this->form_validation->set_error_delimiters('<div class="error">', '</div>'); //Set Validate Rule $this->form_validation->set_rules('txt_email', 'Email', 'trim|required|valid_email'); $this->form_validation->set_rules('txt_name', 'Name', 'trim|required'); $this->form_validation->set_rules('txt_subject', 'Subject', 'trim|required'); $this->form_validation->set_rules('txt_message', 'Message', 'trim|required'); if ($this->form_validation->run() === FALSE) { $this->load->view('include/header', $data); $this->load->view('home/contact', $data); $this->load->view('include/footer', $data); } else { $message = array( 'created_date' => date("Y-m-d H:i:s"), 'email' => $this->input->post('txt_email'), 'name' => $this->input->post('txt_name'), 'subject' => $this->input->post('txt_subject'), 'message' => $this->input->post('txt_message'), ); $this->contact_model->set_message($message); $this->load->view('include/header', $data); $this->load->view('home/contact_success'); $this->load->view('include/footer', $data); } } } /* End of file home.php */ /* Location: ./application/controllers/home.php */
00-techstorm
trunk/application/controllers/home.php
PHP
gpl3
3,407
<?php /* * --------------------------------------------------------------- * APPLICATION ENVIRONMENT * --------------------------------------------------------------- * * You can load different configurations depending on your * current environment. Setting the environment also influences * things like logging and error reporting. * * This can be set to anything, but default usage is: * * development * testing * production * * NOTE: If you change these, also change the error_reporting() code below * */ define('ENVIRONMENT', 'development'); /* * --------------------------------------------------------------- * ERROR REPORTING * --------------------------------------------------------------- * * Different environments will require different levels of error reporting. * By default development will show errors but testing and live will hide them. */ if (defined('ENVIRONMENT')) { switch (ENVIRONMENT) { case 'development': error_reporting(E_ALL); ini_set("display_errors", "on"); break; case 'testing': case 'production': error_reporting(0); break; default: exit('The application environment is not set correctly.'); } } /* * --------------------------------------------------------------- * SYSTEM FOLDER NAME * --------------------------------------------------------------- * * This variable must contain the name of your "system" folder. * Include the path if the folder is not in the same directory * as this file. * */ $system_path = 'system'; /* * --------------------------------------------------------------- * APPLICATION FOLDER NAME * --------------------------------------------------------------- * * If you want this front controller to use a different "application" * folder then the default one you can set its name here. The folder * can also be renamed or relocated anywhere on your server. If * you do, use a full server path. For more info please see the user guide: * http://codeigniter.com/user_guide/general/managing_apps.html * * NO TRAILING SLASH! * */ $application_folder = 'application'; /* * -------------------------------------------------------------------- * DEFAULT CONTROLLER * -------------------------------------------------------------------- * * Normally you will set your default controller in the routes.php file. * You can, however, force a custom routing by hard-coding a * specific controller class/function here. For most applications, you * WILL NOT set your routing here, but it's an option for those * special instances where you might want to override the standard * routing in a specific front controller that shares a common CI installation. * * IMPORTANT: If you set the routing here, NO OTHER controller will be * callable. In essence, this preference limits your application to ONE * specific controller. Leave the function name blank if you need * to call functions dynamically via the URI. * * Un-comment the $routing array below to use this feature * */ // The directory name, relative to the "controllers" folder. Leave blank // if your controller is not in a sub-folder within the "controllers" folder // $routing['directory'] = ''; // The controller class file name. Example: Mycontroller // $routing['controller'] = ''; // The controller function you wish to be called. // $routing['function'] = ''; /* * ------------------------------------------------------------------- * CUSTOM CONFIG VALUES * ------------------------------------------------------------------- * * The $assign_to_config array below will be passed dynamically to the * config class when initialized. This allows you to set custom config * items or override any default config values found in the config.php file. * This can be handy as it permits you to share one application between * multiple front controller files, with each file containing different * config values. * * Un-comment the $assign_to_config array below to use this feature * */ // $assign_to_config['name_of_config_item'] = 'value of config item'; // -------------------------------------------------------------------- // END OF USER CONFIGURABLE SETTINGS. DO NOT EDIT BELOW THIS LINE // -------------------------------------------------------------------- /* * --------------------------------------------------------------- * Resolve the system path for increased reliability * --------------------------------------------------------------- */ // Set the current directory correctly for CLI requests if (defined('STDIN')) { chdir(dirname(__FILE__)); } if (realpath($system_path) !== FALSE) { $system_path = realpath($system_path) . '/'; } // ensure there's a trailing slash $system_path = rtrim($system_path, '/') . '/'; // Is the system path correct? if (!is_dir($system_path)) { exit("Your system folder path does not appear to be set correctly. Please open the following file and correct this: " . pathinfo(__FILE__, PATHINFO_BASENAME)); } /* * ------------------------------------------------------------------- * Now that we know the path, set the main path constants * ------------------------------------------------------------------- */ // The name of THIS file define('SELF', pathinfo(__FILE__, PATHINFO_BASENAME)); // The PHP file extension // this global constant is deprecated. define('EXT', '.php'); // Path to the system folder define('BASEPATH', str_replace("\\", "/", $system_path)); // Path to the front controller (this file) define('FCPATH', str_replace(SELF, '', __FILE__)); // Name of the "system folder" define('SYSDIR', trim(strrchr(trim(BASEPATH, '/'), '/'), '/')); // The path to the "application" folder if (is_dir($application_folder)) { define('APPPATH', $application_folder . '/'); } else { if (!is_dir(BASEPATH . $application_folder . '/')) { exit("Your application folder path does not appear to be set correctly. Please open the following file and correct this: " . SELF); } define('APPPATH', BASEPATH . $application_folder . '/'); } /* * -------------------------------------------------------------------- * LOAD THE BOOTSTRAP FILE * -------------------------------------------------------------------- * * And away we go... * */ require_once BASEPATH . 'core/CodeIgniter.php'; /* End of file index.php */ /* Location: ./index.php */
00-techstorm
trunk/index.php
PHP
gpl3
6,471
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
00-techstorm
trunk/system/index.html
HTML
gpl3
114
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
00-techstorm
trunk/system/language/index.html
HTML
gpl3
114
<?php $lang['date_year'] = "Year"; $lang['date_years'] = "Years"; $lang['date_month'] = "Month"; $lang['date_months'] = "Months"; $lang['date_week'] = "Week"; $lang['date_weeks'] = "Weeks"; $lang['date_day'] = "Day"; $lang['date_days'] = "Days"; $lang['date_hour'] = "Hour"; $lang['date_hours'] = "Hours"; $lang['date_minute'] = "Minute"; $lang['date_minutes'] = "Minutes"; $lang['date_second'] = "Second"; $lang['date_seconds'] = "Seconds"; $lang['UM12'] = '(UTC -12:00) Baker/Howland Island'; $lang['UM11'] = '(UTC -11:00) Samoa Time Zone, Niue'; $lang['UM10'] = '(UTC -10:00) Hawaii-Aleutian Standard Time, Cook Islands, Tahiti'; $lang['UM95'] = '(UTC -9:30) Marquesas Islands'; $lang['UM9'] = '(UTC -9:00) Alaska Standard Time, Gambier Islands'; $lang['UM8'] = '(UTC -8:00) Pacific Standard Time, Clipperton Island'; $lang['UM7'] = '(UTC -7:00) Mountain Standard Time'; $lang['UM6'] = '(UTC -6:00) Central Standard Time'; $lang['UM5'] = '(UTC -5:00) Eastern Standard Time, Western Caribbean Standard Time'; $lang['UM45'] = '(UTC -4:30) Venezuelan Standard Time'; $lang['UM4'] = '(UTC -4:00) Atlantic Standard Time, Eastern Caribbean Standard Time'; $lang['UM35'] = '(UTC -3:30) Newfoundland Standard Time'; $lang['UM3'] = '(UTC -3:00) Argentina, Brazil, French Guiana, Uruguay'; $lang['UM2'] = '(UTC -2:00) South Georgia/South Sandwich Islands'; $lang['UM1'] = '(UTC -1:00) Azores, Cape Verde Islands'; $lang['UTC'] = '(UTC) Greenwich Mean Time, Western European Time'; $lang['UP1'] = '(UTC +1:00) Central European Time, West Africa Time'; $lang['UP2'] = '(UTC +2:00) Central Africa Time, Eastern European Time, Kaliningrad Time'; $lang['UP3'] = '(UTC +3:00) Moscow Time, East Africa Time'; $lang['UP35'] = '(UTC +3:30) Iran Standard Time'; $lang['UP4'] = '(UTC +4:00) Azerbaijan Standard Time, Samara Time'; $lang['UP45'] = '(UTC +4:30) Afghanistan'; $lang['UP5'] = '(UTC +5:00) Pakistan Standard Time, Yekaterinburg Time'; $lang['UP55'] = '(UTC +5:30) Indian Standard Time, Sri Lanka Time'; $lang['UP575'] = '(UTC +5:45) Nepal Time'; $lang['UP6'] = '(UTC +6:00) Bangladesh Standard Time, Bhutan Time, Omsk Time'; $lang['UP65'] = '(UTC +6:30) Cocos Islands, Myanmar'; $lang['UP7'] = '(UTC +7:00) Krasnoyarsk Time, Cambodia, Laos, Thailand, Vietnam'; $lang['UP8'] = '(UTC +8:00) Australian Western Standard Time, Beijing Time, Irkutsk Time'; $lang['UP875'] = '(UTC +8:45) Australian Central Western Standard Time'; $lang['UP9'] = '(UTC +9:00) Japan Standard Time, Korea Standard Time, Yakutsk Time'; $lang['UP95'] = '(UTC +9:30) Australian Central Standard Time'; $lang['UP10'] = '(UTC +10:00) Australian Eastern Standard Time, Vladivostok Time'; $lang['UP105'] = '(UTC +10:30) Lord Howe Island'; $lang['UP11'] = '(UTC +11:00) Magadan Time, Solomon Islands, Vanuatu'; $lang['UP115'] = '(UTC +11:30) Norfolk Island'; $lang['UP12'] = '(UTC +12:00) Fiji, Gilbert Islands, Kamchatka Time, New Zealand Standard Time'; $lang['UP1275'] = '(UTC +12:45) Chatham Islands Standard Time'; $lang['UP13'] = '(UTC +13:00) Phoenix Islands Time, Tonga'; $lang['UP14'] = '(UTC +14:00) Line Islands'; /* End of file date_lang.php */ /* Location: ./system/language/english/date_lang.php */
00-techstorm
trunk/system/language/english/date_lang.php
PHP
gpl3
3,177
<?php $lang['terabyte_abbr'] = "TB"; $lang['gigabyte_abbr'] = "GB"; $lang['megabyte_abbr'] = "MB"; $lang['kilobyte_abbr'] = "KB"; $lang['bytes'] = "Bytes"; /* End of file number_lang.php */ /* Location: ./system/language/english/number_lang.php */
00-techstorm
trunk/system/language/english/number_lang.php
PHP
gpl3
249
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
00-techstorm
trunk/system/language/english/index.html
HTML
gpl3
114
<?php $lang['email_must_be_array'] = "The email validation method must be passed an array."; $lang['email_invalid_address'] = "Invalid email address: %s"; $lang['email_attachment_missing'] = "Unable to locate the following email attachment: %s"; $lang['email_attachment_unreadable'] = "Unable to open this attachment: %s"; $lang['email_no_recipients'] = "You must include recipients: To, Cc, or Bcc"; $lang['email_send_failure_phpmail'] = "Unable to send email using PHP mail(). Your server might not be configured to send mail using this method."; $lang['email_send_failure_sendmail'] = "Unable to send email using PHP Sendmail. Your server might not be configured to send mail using this method."; $lang['email_send_failure_smtp'] = "Unable to send email using PHP SMTP. Your server might not be configured to send mail using this method."; $lang['email_sent'] = "Your message has been successfully sent using the following protocol: %s"; $lang['email_no_socket'] = "Unable to open a socket to Sendmail. Please check settings."; $lang['email_no_hostname'] = "You did not specify a SMTP hostname."; $lang['email_smtp_error'] = "The following SMTP error was encountered: %s"; $lang['email_no_smtp_unpw'] = "Error: You must assign a SMTP username and password."; $lang['email_failed_smtp_login'] = "Failed to send AUTH LOGIN command. Error: %s"; $lang['email_smtp_auth_un'] = "Failed to authenticate username. Error: %s"; $lang['email_smtp_auth_pw'] = "Failed to authenticate password. Error: %s"; $lang['email_smtp_data_failure'] = "Unable to send data: %s"; $lang['email_exit_status'] = "Exit status code: %s"; /* End of file email_lang.php */ /* Location: ./system/language/english/email_lang.php */
00-techstorm
trunk/system/language/english/email_lang.php
PHP
gpl3
1,707
<?php $lang['required'] = "The %s field is required."; $lang['isset'] = "The %s field must have a value."; $lang['valid_email'] = "The %s field must contain a valid email address."; $lang['valid_emails'] = "The %s field must contain all valid email addresses."; $lang['valid_url'] = "The %s field must contain a valid URL."; $lang['valid_ip'] = "The %s field must contain a valid IP."; $lang['min_length'] = "The %s field must be at least %s characters in length."; $lang['max_length'] = "The %s field can not exceed %s characters in length."; $lang['exact_length'] = "The %s field must be exactly %s characters in length."; $lang['alpha'] = "The %s field may only contain alphabetical characters."; $lang['alpha_numeric'] = "The %s field may only contain alpha-numeric characters."; $lang['alpha_dash'] = "The %s field may only contain alpha-numeric characters, underscores, and dashes."; $lang['numeric'] = "The %s field must contain only numbers."; $lang['is_numeric'] = "The %s field must contain only numeric characters."; $lang['integer'] = "The %s field must contain an integer."; $lang['regex_match'] = "The %s field is not in the correct format."; $lang['matches'] = "The %s field does not match the %s field."; $lang['is_unique'] = "The %s field must contain a unique value."; $lang['is_natural'] = "The %s field must contain only positive numbers."; $lang['is_natural_no_zero'] = "The %s field must contain a number greater than zero."; $lang['decimal'] = "The %s field must contain a decimal number."; $lang['less_than'] = "The %s field must contain a number less than %s."; $lang['greater_than'] = "The %s field must contain a number greater than %s."; /* End of file form_validation_lang.php */ /* Location: ./system/language/english/form_validation_lang.php */
00-techstorm
trunk/system/language/english/form_validation_lang.php
PHP
gpl3
1,819
<?php $lang['imglib_source_image_required'] = "You must specify a source image in your preferences."; $lang['imglib_gd_required'] = "The GD image library is required for this feature."; $lang['imglib_gd_required_for_props'] = "Your server must support the GD image library in order to determine the image properties."; $lang['imglib_unsupported_imagecreate'] = "Your server does not support the GD function required to process this type of image."; $lang['imglib_gif_not_supported'] = "GIF images are often not supported due to licensing restrictions. You may have to use JPG or PNG images instead."; $lang['imglib_jpg_not_supported'] = "JPG images are not supported."; $lang['imglib_png_not_supported'] = "PNG images are not supported."; $lang['imglib_jpg_or_png_required'] = "The image resize protocol specified in your preferences only works with JPEG or PNG image types."; $lang['imglib_copy_error'] = "An error was encountered while attempting to replace the file. Please make sure your file directory is writable."; $lang['imglib_rotate_unsupported'] = "Image rotation does not appear to be supported by your server."; $lang['imglib_libpath_invalid'] = "The path to your image library is not correct. Please set the correct path in your image preferences."; $lang['imglib_image_process_failed'] = "Image processing failed. Please verify that your server supports the chosen protocol and that the path to your image library is correct."; $lang['imglib_rotation_angle_required'] = "An angle of rotation is required to rotate the image."; $lang['imglib_writing_failed_gif'] = "GIF image."; $lang['imglib_invalid_path'] = "The path to the image is not correct."; $lang['imglib_copy_failed'] = "The image copy routine failed."; $lang['imglib_missing_font'] = "Unable to find a font to use."; $lang['imglib_save_failed'] = "Unable to save the image. Please make sure the image and file directory are writable."; /* End of file imglib_lang.php */ /* Location: ./system/language/english/imglib_lang.php */
00-techstorm
trunk/system/language/english/imglib_lang.php
PHP
gpl3
2,011
<?php $lang['cal_su'] = "Su"; $lang['cal_mo'] = "Mo"; $lang['cal_tu'] = "Tu"; $lang['cal_we'] = "We"; $lang['cal_th'] = "Th"; $lang['cal_fr'] = "Fr"; $lang['cal_sa'] = "Sa"; $lang['cal_sun'] = "Sun"; $lang['cal_mon'] = "Mon"; $lang['cal_tue'] = "Tue"; $lang['cal_wed'] = "Wed"; $lang['cal_thu'] = "Thu"; $lang['cal_fri'] = "Fri"; $lang['cal_sat'] = "Sat"; $lang['cal_sunday'] = "Sunday"; $lang['cal_monday'] = "Monday"; $lang['cal_tuesday'] = "Tuesday"; $lang['cal_wednesday'] = "Wednesday"; $lang['cal_thursday'] = "Thursday"; $lang['cal_friday'] = "Friday"; $lang['cal_saturday'] = "Saturday"; $lang['cal_jan'] = "Jan"; $lang['cal_feb'] = "Feb"; $lang['cal_mar'] = "Mar"; $lang['cal_apr'] = "Apr"; $lang['cal_may'] = "May"; $lang['cal_jun'] = "Jun"; $lang['cal_jul'] = "Jul"; $lang['cal_aug'] = "Aug"; $lang['cal_sep'] = "Sep"; $lang['cal_oct'] = "Oct"; $lang['cal_nov'] = "Nov"; $lang['cal_dec'] = "Dec"; $lang['cal_january'] = "January"; $lang['cal_february'] = "February"; $lang['cal_march'] = "March"; $lang['cal_april'] = "April"; $lang['cal_mayl'] = "May"; $lang['cal_june'] = "June"; $lang['cal_july'] = "July"; $lang['cal_august'] = "August"; $lang['cal_september'] = "September"; $lang['cal_october'] = "October"; $lang['cal_november'] = "November"; $lang['cal_december'] = "December"; /* End of file calendar_lang.php */ /* Location: ./system/language/english/calendar_lang.php */
00-techstorm
trunk/system/language/english/calendar_lang.php
PHP
gpl3
1,437
<?php $lang['ftp_no_connection'] = "Unable to locate a valid connection ID. Please make sure you are connected before peforming any file routines."; $lang['ftp_unable_to_connect'] = "Unable to connect to your FTP server using the supplied hostname."; $lang['ftp_unable_to_login'] = "Unable to login to your FTP server. Please check your username and password."; $lang['ftp_unable_to_makdir'] = "Unable to create the directory you have specified."; $lang['ftp_unable_to_changedir'] = "Unable to change directories."; $lang['ftp_unable_to_chmod'] = "Unable to set file permissions. Please check your path. Note: This feature is only available in PHP 5 or higher."; $lang['ftp_unable_to_upload'] = "Unable to upload the specified file. Please check your path."; $lang['ftp_unable_to_download'] = "Unable to download the specified file. Please check your path."; $lang['ftp_no_source_file'] = "Unable to locate the source file. Please check your path."; $lang['ftp_unable_to_rename'] = "Unable to rename the file."; $lang['ftp_unable_to_delete'] = "Unable to delete the file."; $lang['ftp_unable_to_move'] = "Unable to move the file. Please make sure the destination directory exists."; /* End of file ftp_lang.php */ /* Location: ./system/language/english/ftp_lang.php */
00-techstorm
trunk/system/language/english/ftp_lang.php
PHP
gpl3
1,285
<?php $lang['migration_none_found'] = "No migrations were found."; $lang['migration_not_found'] = "This migration could not be found."; $lang['migration_multiple_version'] = "This are multiple migrations with the same version number: %d."; $lang['migration_class_doesnt_exist'] = "The migration class \"%s\" could not be found."; $lang['migration_missing_up_method'] = "The migration class \"%s\" is missing an 'up' method."; $lang['migration_missing_down_method'] = "The migration class \"%s\" is missing an 'down' method."; $lang['migration_invalid_filename'] = "Migration \"%s\" has an invalid filename."; /* End of file migration_lang.php */ /* Location: ./system/language/english/migration_lang.php */
00-techstorm
trunk/system/language/english/migration_lang.php
PHP
gpl3
715
<?php $lang['ut_test_name'] = 'Test Name'; $lang['ut_test_datatype'] = 'Test Datatype'; $lang['ut_res_datatype'] = 'Expected Datatype'; $lang['ut_result'] = 'Result'; $lang['ut_undefined'] = 'Undefined Test Name'; $lang['ut_file'] = 'File Name'; $lang['ut_line'] = 'Line Number'; $lang['ut_passed'] = 'Passed'; $lang['ut_failed'] = 'Failed'; $lang['ut_boolean'] = 'Boolean'; $lang['ut_integer'] = 'Integer'; $lang['ut_float'] = 'Float'; $lang['ut_double'] = 'Float'; // can be the same as float $lang['ut_string'] = 'String'; $lang['ut_array'] = 'Array'; $lang['ut_object'] = 'Object'; $lang['ut_resource'] = 'Resource'; $lang['ut_null'] = 'Null'; $lang['ut_notes'] = 'Notes'; /* End of file unit_test_lang.php */ /* Location: ./system/language/english/unit_test_lang.php */
00-techstorm
trunk/system/language/english/unit_test_lang.php
PHP
gpl3
808
<?php $lang['profiler_database'] = 'DATABASE'; $lang['profiler_controller_info'] = 'CLASS/METHOD'; $lang['profiler_benchmarks'] = 'BENCHMARKS'; $lang['profiler_queries'] = 'QUERIES'; $lang['profiler_get_data'] = 'GET DATA'; $lang['profiler_post_data'] = 'POST DATA'; $lang['profiler_uri_string'] = 'URI STRING'; $lang['profiler_memory_usage'] = 'MEMORY USAGE'; $lang['profiler_config'] = 'CONFIG VARIABLES'; $lang['profiler_session_data'] = 'SESSION DATA'; $lang['profiler_headers'] = 'HTTP HEADERS'; $lang['profiler_no_db'] = 'Database driver is not currently loaded'; $lang['profiler_no_queries'] = 'No queries were run'; $lang['profiler_no_post'] = 'No POST data exists'; $lang['profiler_no_get'] = 'No GET data exists'; $lang['profiler_no_uri'] = 'No URI data exists'; $lang['profiler_no_memory'] = 'Memory Usage Unavailable'; $lang['profiler_no_profiles'] = 'No Profile data - all Profiler sections have been disabled.'; $lang['profiler_section_hide'] = 'Hide'; $lang['profiler_section_show'] = 'Show'; /* End of file profiler_lang.php */ /* Location: ./system/language/english/profiler_lang.php */
00-techstorm
trunk/system/language/english/profiler_lang.php
PHP
gpl3
1,117
<?php $lang['db_invalid_connection_str'] = 'Unable to determine the database settings based on the connection string you submitted.'; $lang['db_unable_to_connect'] = 'Unable to connect to your database server using the provided settings.'; $lang['db_unable_to_select'] = 'Unable to select the specified database: %s'; $lang['db_unable_to_create'] = 'Unable to create the specified database: %s'; $lang['db_invalid_query'] = 'The query you submitted is not valid.'; $lang['db_must_set_table'] = 'You must set the database table to be used with your query.'; $lang['db_must_use_set'] = 'You must use the "set" method to update an entry.'; $lang['db_must_use_index'] = 'You must specify an index to match on for batch updates.'; $lang['db_batch_missing_index'] = 'One or more rows submitted for batch updating is missing the specified index.'; $lang['db_must_use_where'] = 'Updates are not allowed unless they contain a "where" clause.'; $lang['db_del_must_use_where'] = 'Deletes are not allowed unless they contain a "where" or "like" clause.'; $lang['db_field_param_missing'] = 'To fetch fields requires the name of the table as a parameter.'; $lang['db_unsupported_function'] = 'This feature is not available for the database you are using.'; $lang['db_transaction_failure'] = 'Transaction failure: Rollback performed.'; $lang['db_unable_to_drop'] = 'Unable to drop the specified database.'; $lang['db_unsuported_feature'] = 'Unsupported feature of the database platform you are using.'; $lang['db_unsuported_compression'] = 'The file compression format you chose is not supported by your server.'; $lang['db_filepath_error'] = 'Unable to write data to the file path you have submitted.'; $lang['db_invalid_cache_path'] = 'The cache path you submitted is not valid or writable.'; $lang['db_table_name_required'] = 'A table name is required for that operation.'; $lang['db_column_name_required'] = 'A column name is required for that operation.'; $lang['db_column_definition_required'] = 'A column definition is required for that operation.'; $lang['db_unable_to_set_charset'] = 'Unable to set client connection character set: %s'; $lang['db_error_heading'] = 'A Database Error Occurred'; /* End of file db_lang.php */ /* Location: ./system/language/english/db_lang.php */
00-techstorm
trunk/system/language/english/db_lang.php
PHP
gpl3
2,273
<?php $lang['upload_userfile_not_set'] = "Unable to find a post variable called userfile."; $lang['upload_file_exceeds_limit'] = "The uploaded file exceeds the maximum allowed size in your PHP configuration file."; $lang['upload_file_exceeds_form_limit'] = "The uploaded file exceeds the maximum size allowed by the submission form."; $lang['upload_file_partial'] = "The file was only partially uploaded."; $lang['upload_no_temp_directory'] = "The temporary folder is missing."; $lang['upload_unable_to_write_file'] = "The file could not be written to disk."; $lang['upload_stopped_by_extension'] = "The file upload was stopped by extension."; $lang['upload_no_file_selected'] = "You did not select a file to upload."; $lang['upload_invalid_filetype'] = "The filetype you are attempting to upload is not allowed."; $lang['upload_invalid_filesize'] = "The file you are attempting to upload is larger than the permitted size."; $lang['upload_invalid_dimensions'] = "The image you are attempting to upload exceedes the maximum height or width."; $lang['upload_destination_error'] = "A problem was encountered while attempting to move the uploaded file to the final destination."; $lang['upload_no_filepath'] = "The upload path does not appear to be valid."; $lang['upload_no_file_types'] = "You have not specified any allowed file types."; $lang['upload_bad_filename'] = "The file name you submitted already exists on the server."; $lang['upload_not_writable'] = "The upload destination folder does not appear to be writable."; /* End of file upload_lang.php */ /* Location: ./system/language/english/upload_lang.php */
00-techstorm
trunk/system/language/english/upload_lang.php
PHP
gpl3
1,619
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); /** * CodeIgniter * * An open source application development framework for PHP 5.1.6 or newer * * @package CodeIgniter * @author ExpressionEngine Dev Team * @copyright Copyright (c) 2008 - 2014, EllisLab, Inc. * @license http://codeigniter.com/user_guide/license.html * @link http://codeigniter.com * @since Version 1.0 * @filesource */ // ------------------------------------------------------------------------ /** * CodeIgniter Number Helpers * * @package CodeIgniter * @subpackage Helpers * @category Helpers * @author ExpressionEngine Dev Team * @link http://codeigniter.com/user_guide/helpers/number_helper.html */ // ------------------------------------------------------------------------ /** * Formats a numbers as bytes, based on size, and adds the appropriate suffix * * @access public * @param mixed // will be cast as int * @return string */ if ( ! function_exists('byte_format')) { function byte_format($num, $precision = 1) { $CI =& get_instance(); $CI->lang->load('number'); if ($num >= 1000000000000) { $num = round($num / 1099511627776, $precision); $unit = $CI->lang->line('terabyte_abbr'); } elseif ($num >= 1000000000) { $num = round($num / 1073741824, $precision); $unit = $CI->lang->line('gigabyte_abbr'); } elseif ($num >= 1000000) { $num = round($num / 1048576, $precision); $unit = $CI->lang->line('megabyte_abbr'); } elseif ($num >= 1000) { $num = round($num / 1024, $precision); $unit = $CI->lang->line('kilobyte_abbr'); } else { $unit = $CI->lang->line('bytes'); return number_format($num).' '.$unit; } return number_format($num, $precision).' '.$unit; } } /* End of file number_helper.php */ /* Location: ./system/helpers/number_helper.php */
00-techstorm
trunk/system/helpers/number_helper.php
PHP
gpl3
1,859
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); /** * CodeIgniter * * An open source application development framework for PHP 5.1.6 or newer * * @package CodeIgniter * @author ExpressionEngine Dev Team * @copyright Copyright (c) 2008 - 2014, EllisLab, Inc. * @license http://codeigniter.com/user_guide/license.html * @link http://codeigniter.com * @since Version 1.0 * @filesource */ // ------------------------------------------------------------------------ /** * CodeIgniter Language Helpers * * @package CodeIgniter * @subpackage Helpers * @category Helpers * @author ExpressionEngine Dev Team * @link http://codeigniter.com/user_guide/helpers/language_helper.html */ // ------------------------------------------------------------------------ /** * Lang * * Fetches a language variable and optionally outputs a form label * * @access public * @param string the language line * @param string the id of the form element * @return string */ if ( ! function_exists('lang')) { function lang($line, $id = '') { $CI =& get_instance(); $line = $CI->lang->line($line); if ($id != '') { $line = '<label for="'.$id.'">'.$line."</label>"; } return $line; } } // ------------------------------------------------------------------------ /* End of file language_helper.php */ /* Location: ./system/helpers/language_helper.php */
00-techstorm
trunk/system/helpers/language_helper.php
PHP
gpl3
1,409
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); /** * CodeIgniter * * An open source application development framework for PHP 5.1.6 or newer * * @package CodeIgniter * @author ExpressionEngine Dev Team * @copyright Copyright (c) 2008 - 2014, EllisLab, Inc. * @license http://codeigniter.com/user_guide/license.html * @link http://codeigniter.com * @since Version 1.0 * @filesource */ // ------------------------------------------------------------------------ /** * CodeIgniter Cookie Helpers * * @package CodeIgniter * @subpackage Helpers * @category Helpers * @author ExpressionEngine Dev Team * @link http://codeigniter.com/user_guide/helpers/cookie_helper.html */ // ------------------------------------------------------------------------ /** * Set cookie * * Accepts six parameter, or you can submit an associative * array in the first parameter containing all the values. * * @access public * @param mixed * @param string the value of the cookie * @param string the number of seconds until expiration * @param string the cookie domain. Usually: .yourdomain.com * @param string the cookie path * @param string the cookie prefix * @return void */ if ( ! function_exists('set_cookie')) { function set_cookie($name = '', $value = '', $expire = '', $domain = '', $path = '/', $prefix = '', $secure = FALSE) { // Set the config file options $CI =& get_instance(); $CI->input->set_cookie($name, $value, $expire, $domain, $path, $prefix, $secure); } } // -------------------------------------------------------------------- /** * Fetch an item from the COOKIE array * * @access public * @param string * @param bool * @return mixed */ if ( ! function_exists('get_cookie')) { function get_cookie($index = '', $xss_clean = FALSE) { $CI =& get_instance(); $prefix = ''; if ( ! isset($_COOKIE[$index]) && config_item('cookie_prefix') != '') { $prefix = config_item('cookie_prefix'); } return $CI->input->cookie($prefix.$index, $xss_clean); } } // -------------------------------------------------------------------- /** * Delete a COOKIE * * @param mixed * @param string the cookie domain. Usually: .yourdomain.com * @param string the cookie path * @param string the cookie prefix * @return void */ if ( ! function_exists('delete_cookie')) { function delete_cookie($name = '', $domain = '', $path = '/', $prefix = '') { set_cookie($name, '', '', $domain, $path, $prefix); } } /* End of file cookie_helper.php */ /* Location: ./system/helpers/cookie_helper.php */
00-techstorm
trunk/system/helpers/cookie_helper.php
PHP
gpl3
2,591
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); /** * CodeIgniter * * An open source application development framework for PHP 5.1.6 or newer * * @package CodeIgniter * @author ExpressionEngine Dev Team * @copyright Copyright (c) 2008 - 2014, EllisLab, Inc. * @license http://codeigniter.com/user_guide/license.html * @link http://codeigniter.com * @since Version 1.0 * @filesource */ // ------------------------------------------------------------------------ /** * CodeIgniter Security Helpers * * @package CodeIgniter * @subpackage Helpers * @category Helpers * @author ExpressionEngine Dev Team * @link http://codeigniter.com/user_guide/helpers/security_helper.html */ // ------------------------------------------------------------------------ /** * XSS Filtering * * @access public * @param string * @param bool whether or not the content is an image file * @return string */ if ( ! function_exists('xss_clean')) { function xss_clean($str, $is_image = FALSE) { $CI =& get_instance(); return $CI->security->xss_clean($str, $is_image); } } // ------------------------------------------------------------------------ /** * Sanitize Filename * * @access public * @param string * @return string */ if ( ! function_exists('sanitize_filename')) { function sanitize_filename($filename) { $CI =& get_instance(); return $CI->security->sanitize_filename($filename); } } // -------------------------------------------------------------------- /** * Hash encode a string * * @access public * @param string * @return string */ if ( ! function_exists('do_hash')) { function do_hash($str, $type = 'sha1') { if ($type == 'sha1') { return sha1($str); } else { return md5($str); } } } // ------------------------------------------------------------------------ /** * Strip Image Tags * * @access public * @param string * @return string */ if ( ! function_exists('strip_image_tags')) { function strip_image_tags($str) { $str = preg_replace("#<img\s+.*?src\s*=\s*[\"'](.+?)[\"'].*?\>#", "\\1", $str); $str = preg_replace("#<img\s+.*?src\s*=\s*(.+?).*?\>#", "\\1", $str); return $str; } } // ------------------------------------------------------------------------ /** * Convert PHP tags to entities * * @access public * @param string * @return string */ if ( ! function_exists('encode_php_tags')) { function encode_php_tags($str) { return str_replace(array('<?php', '<?PHP', '<?', '?>'), array('&lt;?php', '&lt;?PHP', '&lt;?', '?&gt;'), $str); } } /* End of file security_helper.php */ /* Location: ./system/helpers/security_helper.php */
00-techstorm
trunk/system/helpers/security_helper.php
PHP
gpl3
2,675
<html> <head> <title>403 Forbidden</title> </head> <body> <p>Directory access is forbidden.</p> </body> </html>
00-techstorm
trunk/system/helpers/index.html
HTML
gpl3
114
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); /** * CodeIgniter * * An open source application development framework for PHP 5.1.6 or newer * * @package CodeIgniter * @author ExpressionEngine Dev Team * @copyright Copyright (c) 2008 - 2014, EllisLab, Inc. * @license http://codeigniter.com/user_guide/license.html * @link http://codeigniter.com * @since Version 1.0 * @filesource */ // ------------------------------------------------------------------------ /** * CodeIgniter Directory Helpers * * @package CodeIgniter * @subpackage Helpers * @category Helpers * @author ExpressionEngine Dev Team * @link http://codeigniter.com/user_guide/helpers/directory_helper.html */ // ------------------------------------------------------------------------ /** * Create a Directory Map * * Reads the specified directory and builds an array * representation of it. Sub-folders contained with the * directory will be mapped as well. * * @access public * @param string path to source * @param int depth of directories to traverse (0 = fully recursive, 1 = current dir, etc) * @return array */ if ( ! function_exists('directory_map')) { function directory_map($source_dir, $directory_depth = 0, $hidden = FALSE) { if ($fp = @opendir($source_dir)) { $filedata = array(); $new_depth = $directory_depth - 1; $source_dir = rtrim($source_dir, DIRECTORY_SEPARATOR).DIRECTORY_SEPARATOR; while (FALSE !== ($file = readdir($fp))) { // Remove '.', '..', and hidden files [optional] if ( ! trim($file, '.') OR ($hidden == FALSE && $file[0] == '.')) { continue; } if (($directory_depth < 1 OR $new_depth > 0) && @is_dir($source_dir.$file)) { $filedata[$file] = directory_map($source_dir.$file.DIRECTORY_SEPARATOR, $new_depth, $hidden); } else { $filedata[] = $file; } } closedir($fp); return $filedata; } return FALSE; } } /* End of file directory_helper.php */ /* Location: ./system/helpers/directory_helper.php */
00-techstorm
trunk/system/helpers/directory_helper.php
PHP
gpl3
2,062
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); /** * CodeIgniter * * An open source application development framework for PHP 5.1.6 or newer * * @package CodeIgniter * @author ExpressionEngine Dev Team * @copyright Copyright (c) 2008 - 2014, EllisLab, Inc. * @license http://codeigniter.com/user_guide/license.html * @link http://codeigniter.com * @since Version 1.0 * @filesource */ // ------------------------------------------------------------------------ /** * CodeIgniter Email Helpers * * @package CodeIgniter * @subpackage Helpers * @category Helpers * @author ExpressionEngine Dev Team * @link http://codeigniter.com/user_guide/helpers/email_helper.html */ // ------------------------------------------------------------------------ /** * Validate email address * * @access public * @return bool */ if ( ! function_exists('valid_email')) { function valid_email($address) { return ( ! preg_match("/^([a-z0-9\+_\-]+)(\.[a-z0-9\+_\-]+)*@([a-z0-9\-]+\.)+[a-z]{2,6}$/ix", $address)) ? FALSE : TRUE; } } // ------------------------------------------------------------------------ /** * Send an email * * @access public * @return bool */ if ( ! function_exists('send_email')) { function send_email($recipient, $subject = 'Test email', $message = 'Hello World') { return mail($recipient, $subject, $message); } } /* End of file email_helper.php */ /* Location: ./system/helpers/email_helper.php */
00-techstorm
trunk/system/helpers/email_helper.php
PHP
gpl3
1,483