public static void Main() { ElementBuilder div = new ElementBuilder("div"); div.AddAttribute("id", "page"); div.AddAttribute("class", "big"); div.AddContent("<p>Hello</p>"); Console.WriteLine(div * 2); Console.WriteLine(); ElementBuilder li = new ElementBuilder("li"); li.AddAttribute("class", "nav"); li.AddAttribute("id", "one"); li.AddContent("Hello OOP"); Console.WriteLine(li * 3); Console.WriteLine(); string image = HTMLDispatcher.CreateImage("img.png", "sample img", "sample"); string url = HTMLDispatcher.CreateURL("https:\\\\softuni.bg", "SoftUni", "SoftUni website"); string input = HTMLDispatcher.CreateInput("text", "username", "student"); Console.WriteLine(image); Console.WriteLine(url); Console.WriteLine(input); }
public string CreateURL(string url, string title, string text) { ElementBuilder image = new ElementBuilder("URL"); image.AddAttribute("href", url); image.AddAttribute("title", title); image.AddAttribute("text", text); return image.ToString(); }
public string CreateImage(string imageSource,string alt, string title) { ElementBuilder image = new ElementBuilder("img"); image.AddAttribute("src", imageSource); image.AddAttribute("alt", alt); image.AddAttribute("title", title); return image.ToString(); }
public string CreateInput(string inputType, string name, string value) { ElementBuilder image = new ElementBuilder("input"); image.AddAttribute("input", inputType); image.AddAttribute("name", name); image.AddAttribute("value", value); return image.ToString(); }
static void Main(string[] args) { ElementBuilder div = new ElementBuilder("div"); div.AddAttribute("id", "page"); div.AddAttribute("class", "big"); div.AddContent("<p>Hello</p>"); //Console.WriteLine(div * 2); }
public static ElementBuilder CreateInput(string type = "button", string name = "name", string value = "") { ElementBuilder input = new ElementBuilder("input"); input.AddAttribute("type", type); input.AddAttribute("name", name); input.AddAttribute("value", value); return input; }
public static string CreateImage(string imgSrc, string alt, string title) { ElementBuilder img = new ElementBuilder("img", true); img.AddAttribute("src", imgSrc); img.AddAttribute("alt", alt); img.AddAttribute("title", title); return(img.ToString()); }
public static string CreateInput(string inputType, string nameValue, string titleValue) { ElementBuilder input = new ElementBuilder("input"); input.AddAttribute("name", nameValue); input.AddAttribute("title", titleValue); return(input.ToString()); }
static void Main(string[] args) { ElementBuilder element = new ElementBuilder("div"); element.AddAttribute("id", "page"); element.AddAttribute("class", "big"); element.AddContent("<p>Hello</p>"); Console.WriteLine(element); Console.WriteLine(element * 2); }
public static string CreateDiv(string id, string style, string content) { ElementBuilder div = new ElementBuilder("div"); div.AddAttribute("id", id); div.AddAttribute("style", style); div.AddContent(content); return(div.ToString()); }
public static ElementBuilder CreateUrl(string url, string title, string text) { ElementBuilder link = new ElementBuilder("a"); link.AddAttribute("href", url); link.AddAttribute("title", title); link.AddContent(text); return link; }
public static string CreateURL(string url, string title, string text) { ElementBuilder e = new ElementBuilder("a"); e.AddAttribute("href", url); e.AddAttribute("title", title); e.AddContent(text); return e.ToString(); }
public static string CreateHyperlink(string url, string title, string text) { ElementBuilder hyperlink = new ElementBuilder("a"); hyperlink.AddAttribute("url", url); hyperlink.AddAttribute("title", title); hyperlink.AddContent(text); return(hyperlink.ToString()); }
public static ElementBuilder CreateURL(string url, string title, string text) { ElementBuilder urlTag = new ElementBuilder("a"); urlTag.AddAttribute("href", url); urlTag.AddAttribute("title", title); urlTag.AddContent(text); return urlTag; }
public static ElementBuilder CreateImage(string src, string alt, string title) { ElementBuilder image = new ElementBuilder("img", true); image.AddAttribute("src", src); image.AddAttribute("alt", alt); image.AddAttribute("title", title); return(image); }
public static ElementBuilder CreateInput(string type, string name, string value) { ElementBuilder input = new ElementBuilder("input", true); input.AddAttribute("type", type); input.AddAttribute("name", name); input.AddAttribute("value", value); return(input); }
public static ElementBuilder CreateURL(string url, string title, string text) { ElementBuilder urlTag = new ElementBuilder("a"); urlTag.AddAttribute("href", url); urlTag.AddAttribute("title", title); urlTag.AddContent(text); return(urlTag); }
public static string CreateImage(string srcValue, string altValue, string titleValue) { ElementBuilder img = new ElementBuilder("img"); img.AddAttribute("src", srcValue); img.AddAttribute("alt", altValue); img.AddAttribute("title", titleValue); return(img.ToString()); }
public static string CreateURL(string hrefValue, string titleValue, string content) { ElementBuilder anchor = new ElementBuilder("a"); anchor.AddAttribute("href", hrefValue); anchor.AddAttribute("title", titleValue); anchor.AddContent(content); return(anchor.ToString()); }
public static string CreateInput(string inputType, string name, string value) { ElementBuilder e = new ElementBuilder("input"); e.AddAttribute("type", inputType); e.AddAttribute("name", name); e.AddAttribute("value", value); return(e.ToString()); }
public static string CreateURL(string url, string title, string text) { ElementBuilder e = new ElementBuilder("a"); e.AddAttribute("href", url); e.AddAttribute("title", title); e.AddContent(text); return(e.ToString()); }
public static ElementBuilder CreateImage(string src, string alt, string title) { ElementBuilder image = new ElementBuilder("img", true); image.AddAttribute("src", src); image.AddAttribute("alt", alt); image.AddAttribute("title", title); return image; }
static void Main(string[] args) { ElementBuilder div = new ElementBuilder("div"); div.AddAttribute("id", "page"); div.AddAttribute("class", "big"); div.AddContent("<p>Hello</p>"); Console.WriteLine(div * 2); Console.WriteLine(HTMLDispatcher.CreateImage("abv.bg", "abv")); Console.WriteLine(HTMLDispatcher.CreateUrl("abv.bg", "abv", "go to abv")); Console.WriteLine(HTMLDispatcher.CreateInput()); }
public static ElementBuilder CreateImage(string imageSource, string alt, string title = null) { ElementBuilder image = new ElementBuilder("img"); image.AddAttribute("src", imageSource); image.AddAttribute("alt", alt); if (title != null) { image.AddAttribute("title", title); } return image; }
public static string CreateImage(string imagSource, string alt, string title) { ElementBuilder element = new ElementBuilder("img"); element.AddAttribute("src", imagSource); element.AddAttribute("alt", alt); element.AddAttribute("title", title); return(element.ToString()); }
public static string CreateImage(string imagSource, string alt, string title) { ElementBuilder element = new ElementBuilder("img"); element.AddAttribute("src", imagSource); element.AddAttribute("alt", alt); element.AddAttribute("title", title); return element.ToString(); }
public static void Main() { ElementBuilder div = new ElementBuilder("div"); div.AddAttribute("id", "page"); div.AddAttribute("class", "big"); div.AddContent("<p>Hello</p>"); Console.WriteLine(div * 2); Console.WriteLine(); Console.WriteLine(HTMLDispatcher.CreateImage("MyDocuments/Pictures", "Beach", "California")); Console.WriteLine(HTMLDispatcher.CreateURL("www.metallica.com", "Metallica", "Official Metallica Website")); Console.WriteLine(HTMLDispatcher.CreateInput("button", "login", "Enter")); }
static void Main() { ElementBuilder div = new ElementBuilder("div"); div.AddAttribute("id", "page"); div.AddAttribute("class", "big"); div.AddContent("<p>Hello</p>"); Console.WriteLine(div * 2); Console.WriteLine(); Console.WriteLine(CreateImage("smiley.gif", "Smiley face", "Project 101")); Console.WriteLine(CreateURL("http://softuni.bg", "SoftUni hyperlink", "Better education")); Console.WriteLine(CreateInput("text", "fname", "Input tag")); }
static void Main() { ElementBuilder div = new ElementBuilder("div"); div.AddAttribute("id", "page"); div.AddAttribute("class", "big"); div.AddContent("<p>Hello</p>"); Console.WriteLine(div * 2); Console.WriteLine(HTMLDispatcher.CreateImage("https://softuni.bg/Content/images/software-university-logo.png", "SoftUni Logo", "THIS ... IS ... SOFTWARE UNIVERSITYYYYYY !!!!")); Console.WriteLine(); string url = HTMLDispatcher.CreateURL("https://softuni.bg/", "SoftUni website", "Welcome to SoftUni"); Console.WriteLine(url); Console.WriteLine(); Console.WriteLine(HTMLDispatcher.CreateInput("comment", "StudentComment", "Enter your comment here")); }
static void Main(string[] args) { ElementBuilder div = new ElementBuilder("div"); div.AddAttribute("id", "page"); div.AddAttribute("class", "big"); div.AddContent("<p>Hello</p>"); Console.WriteLine(div); Console.WriteLine(); Console.WriteLine(div * 2); Console.WriteLine(); ElementBuilder image = HTMLDispatcher.CreateImage("https://softuni.bg/Content/design/logo.png", "Software University", "Software University"); ElementBuilder url = HTMLDispatcher.CreateURL("https://softuni.bg", "Software University", "SoftUni"); ElementBuilder input = HTMLDispatcher.CreateInput("text", "name", "1"); Console.WriteLine(image); Console.WriteLine(url); Console.WriteLine(input); }
static void Main() { //test html element builder ElementBuilder div = new ElementBuilder("div"); div.AddAttribute("id", "page"); div.AddAttribute("class", "big"); div.AddContent("<p>Hello</p>"); div.IsSelfClosed = false; Console.WriteLine(div * 2); //test html dispatcher string myImage = HTMLDispatcher.CreateImage("image1.jpg", "test image", "test image"); Console.WriteLine(myImage); string myLink = HTMLDispatcher.CreateURL("http://www.softuni.bg", "www.softuni.bg", "www.softuni.bg"); Console.WriteLine(myLink); string myInput = HTMLDispatcher.CreateInput("submit", "submit", "Submit"); Console.WriteLine(myInput); }