├── .gitignore
├── test.txt
├── Facebook Scraper
├── Properties
│ ├── Settings.settings
│ ├── Settings.Designer.cs
│ ├── AssemblyInfo.cs
│ ├── Resources.Designer.cs
│ └── Resources.resx
├── Program.cs
├── Form1.Designer.cs
├── Form1.cs
├── ImageCrawler.csproj
└── Form1.resx
├── README.md
├── Facebook Scraper.sln
└── Form1.cs
/.gitignore:
--------------------------------------------------------------------------------
1 | /test.txt
2 |
--------------------------------------------------------------------------------
/test.txt:
--------------------------------------------------------------------------------
1 | my first upload to github
--------------------------------------------------------------------------------
/Facebook Scraper/Properties/Settings.settings:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | Facebook Scraper ,a software to search and extract unique user ID's from facebook pages(Exports ID's of people who have liked pages,commented or liked page posts),groups, posts and events to a CSV file and convert it to Facebook Emails.You can import Emails CSV easily to facebook power editor to get custom audience.
2 | This is a free version of Facebook Scrape. To get the commercial version, please visit:
3 | http://www.botguruz.com/products/facebook-data-extractor/
4 |
--------------------------------------------------------------------------------
/Facebook Scraper/Program.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 | using System.Windows.Forms;
5 |
6 | namespace ImageCrawler
7 | {
8 | static class Program
9 | {
10 | ///
11 | /// The main entry point for the application.
12 | ///
13 | [STAThread]
14 | static void Main()
15 | {
16 | Application.EnableVisualStyles();
17 | Application.SetCompatibleTextRenderingDefault(false);
18 | Application.Run(new Form1());
19 | }
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/Facebook Scraper.sln:
--------------------------------------------------------------------------------
1 |
2 | Microsoft Visual Studio Solution File, Format Version 10.00
3 | # Visual Studio 2008
4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ImageCrawler", "ImageCrawler\ImageCrawler.csproj", "{FC8B58A9-FB29-4329-9C5C-2303E516B132}"
5 | EndProject
6 | Global
7 | GlobalSection(SolutionConfigurationPlatforms) = preSolution
8 | Debug|Any CPU = Debug|Any CPU
9 | Release|Any CPU = Release|Any CPU
10 | EndGlobalSection
11 | GlobalSection(ProjectConfigurationPlatforms) = postSolution
12 | {FC8B58A9-FB29-4329-9C5C-2303E516B132}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
13 | {FC8B58A9-FB29-4329-9C5C-2303E516B132}.Debug|Any CPU.Build.0 = Debug|Any CPU
14 | {FC8B58A9-FB29-4329-9C5C-2303E516B132}.Release|Any CPU.ActiveCfg = Release|Any CPU
15 | {FC8B58A9-FB29-4329-9C5C-2303E516B132}.Release|Any CPU.Build.0 = Release|Any CPU
16 | EndGlobalSection
17 | GlobalSection(SolutionProperties) = preSolution
18 | HideSolutionNode = FALSE
19 | EndGlobalSection
20 | EndGlobal
21 |
--------------------------------------------------------------------------------
/Facebook Scraper/Properties/Settings.Designer.cs:
--------------------------------------------------------------------------------
1 | //------------------------------------------------------------------------------
2 | //
3 | // This code was generated by a tool.
4 | // Runtime Version:2.0.50727.4927
5 | //
6 | // Changes to this file may cause incorrect behavior and will be lost if
7 | // the code is regenerated.
8 | //
9 | //------------------------------------------------------------------------------
10 |
11 | namespace ImageCrawler.Properties
12 | {
13 |
14 |
15 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
16 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "9.0.0.0")]
17 | internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase
18 | {
19 |
20 | private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
21 |
22 | public static Settings Default
23 | {
24 | get
25 | {
26 | return defaultInstance;
27 | }
28 | }
29 | }
30 | }
31 |
--------------------------------------------------------------------------------
/Facebook Scraper/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.CompilerServices;
3 | using System.Runtime.InteropServices;
4 |
5 | // General Information about an assembly is controlled through the following
6 | // set of attributes. Change these attribute values to modify the information
7 | // associated with an assembly.
8 | [assembly: AssemblyTitle("ImageCrawler")]
9 | [assembly: AssemblyDescription("")]
10 | [assembly: AssemblyConfiguration("")]
11 | [assembly: AssemblyCompany("")]
12 | [assembly: AssemblyProduct("ImageCrawler")]
13 | [assembly: AssemblyCopyright("Copyright © 2010")]
14 | [assembly: AssemblyTrademark("")]
15 | [assembly: AssemblyCulture("")]
16 |
17 | // Setting ComVisible to false makes the types in this assembly not visible
18 | // to COM components. If you need to access a type in this assembly from
19 | // COM, set the ComVisible attribute to true on that type.
20 | [assembly: ComVisible(false)]
21 |
22 | // The following GUID is for the ID of the typelib if this project is exposed to COM
23 | [assembly: Guid("b90f6051-edeb-4c4d-9131-851e7a907be0")]
24 |
25 | // Version information for an assembly consists of the following four values:
26 | //
27 | // Major Version
28 | // Minor Version
29 | // Build Number
30 | // Revision
31 | //
32 | // You can specify all the values or you can default the Build and Revision Numbers
33 | // by using the '*' as shown below:
34 | // [assembly: AssemblyVersion("1.0.*")]
35 | [assembly: AssemblyVersion("1.0.0.0")]
36 | [assembly: AssemblyFileVersion("1.0.0.0")]
37 |
--------------------------------------------------------------------------------
/Facebook Scraper/Form1.Designer.cs:
--------------------------------------------------------------------------------
1 | namespace ImageCrawler
2 | {
3 | partial class Form1
4 | {
5 | ///
6 | /// Required designer variable.
7 | ///
8 | private System.ComponentModel.IContainer components = null;
9 |
10 | ///
11 | /// Clean up any resources being used.
12 | ///
13 | /// true if managed resources should be disposed; otherwise, false.
14 | protected override void Dispose(bool disposing)
15 | {
16 | if (disposing && (components != null))
17 | {
18 | components.Dispose();
19 | }
20 | base.Dispose(disposing);
21 | }
22 |
23 | #region Windows Form Designer generated code
24 |
25 | ///
26 | /// Required method for Designer support - do not modify
27 | /// the contents of this method with the code editor.
28 | ///
29 | private void InitializeComponent()
30 | {
31 | this.button1 = new System.Windows.Forms.Button();
32 | this.textBox1 = new System.Windows.Forms.TextBox();
33 | this.SuspendLayout();
34 | //
35 | // button1
36 | //
37 | this.button1.Location = new System.Drawing.Point(98, 161);
38 | this.button1.Name = "button1";
39 | this.button1.Size = new System.Drawing.Size(75, 23);
40 | this.button1.TabIndex = 0;
41 | this.button1.Text = "button1";
42 | this.button1.UseVisualStyleBackColor = true;
43 | this.button1.Click += new System.EventHandler(this.button1_Click);
44 | //
45 | // textBox1
46 | //
47 | this.textBox1.Location = new System.Drawing.Point(64, 80);
48 | this.textBox1.Name = "textBox1";
49 | this.textBox1.Size = new System.Drawing.Size(100, 20);
50 | this.textBox1.TabIndex = 1;
51 | //
52 | // Form1
53 | //
54 | this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
55 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
56 | this.ClientSize = new System.Drawing.Size(322, 262);
57 | this.Controls.Add(this.textBox1);
58 | this.Controls.Add(this.button1);
59 | this.Name = "Form1";
60 | this.Text = "Form1";
61 | this.ResumeLayout(false);
62 | this.PerformLayout();
63 |
64 | }
65 |
66 | #endregion
67 |
68 | private System.Windows.Forms.Button button1;
69 | private System.Windows.Forms.TextBox textBox1;
70 | }
71 | }
72 |
73 |
--------------------------------------------------------------------------------
/Facebook Scraper/Properties/Resources.Designer.cs:
--------------------------------------------------------------------------------
1 | //------------------------------------------------------------------------------
2 | //
3 | // This code was generated by a tool.
4 | // Runtime Version:2.0.50727.4927
5 | //
6 | // Changes to this file may cause incorrect behavior and will be lost if
7 | // the code is regenerated.
8 | //
9 | //------------------------------------------------------------------------------
10 |
11 | namespace ImageCrawler.Properties
12 | {
13 |
14 |
15 | ///
16 | /// A strongly-typed resource class, for looking up localized strings, etc.
17 | ///
18 | // This class was auto-generated by the StronglyTypedResourceBuilder
19 | // class via a tool like ResGen or Visual Studio.
20 | // To add or remove a member, edit your .ResX file then rerun ResGen
21 | // with the /str option, or rebuild your VS project.
22 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "2.0.0.0")]
23 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
24 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
25 | internal class Resources
26 | {
27 |
28 | private static global::System.Resources.ResourceManager resourceMan;
29 |
30 | private static global::System.Globalization.CultureInfo resourceCulture;
31 |
32 | [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
33 | internal Resources()
34 | {
35 | }
36 |
37 | ///
38 | /// Returns the cached ResourceManager instance used by this class.
39 | ///
40 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
41 | internal static global::System.Resources.ResourceManager ResourceManager
42 | {
43 | get
44 | {
45 | if ((resourceMan == null))
46 | {
47 | global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("ImageCrawler.Properties.Resources", typeof(Resources).Assembly);
48 | resourceMan = temp;
49 | }
50 | return resourceMan;
51 | }
52 | }
53 |
54 | ///
55 | /// Overrides the current thread's CurrentUICulture property for all
56 | /// resource lookups using this strongly typed resource class.
57 | ///
58 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
59 | internal static global::System.Globalization.CultureInfo Culture
60 | {
61 | get
62 | {
63 | return resourceCulture;
64 | }
65 | set
66 | {
67 | resourceCulture = value;
68 | }
69 | }
70 | }
71 | }
72 |
--------------------------------------------------------------------------------
/Form1.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.ComponentModel;
4 | using System.Data;
5 | using System.Drawing;
6 | using System.Linq;
7 | using System.Text;
8 | using System.Text.RegularExpressions;
9 | using System.Windows.Forms;
10 | using GlobusLib;
11 | using System.Net;
12 | using System.IO;
13 | using System.Drawing.Imaging;
14 |
15 |
16 | namespace ImageCrawler
17 | {
18 | public partial class Form1 : Form
19 | {
20 | GlobusHttpHelper httpHelper;
21 | GlobusRegex globusRegex;
22 |
23 | List lst = new List();
24 | List lst1 = new List();
25 |
26 | public Form1()
27 | {
28 | httpHelper = new GlobusHttpHelper();
29 | globusRegex = new GlobusRegex();
30 | InitializeComponent();
31 | }
32 | private string imageUrl;
33 | private Bitmap bitmap;
34 | public Form1(string imageUrl)
35 | {
36 | this.imageUrl = "http://lurieunaward.com/1st_Alfredo_Sabat_cartoon2006.jpg";
37 | }
38 | public void Download() {
39 | try {
40 | WebClient client = new WebClient();
41 | Stream stream = client.OpenRead("http://lurieunaward.com/1st_Alfredo_Sabat_cartoon2006.jpg");
42 | bitmap = new Bitmap(stream);
43 | stream.Flush();
44 | stream.Close();
45 | }
46 | catch (Exception e) {
47 | Console.WriteLine(e.Message);
48 | }
49 | }
50 | public Bitmap GetImage() {
51 | return bitmap;
52 | }
53 |
54 | public void SaveImage() {
55 | if (bitmap != null) {
56 | bitmap.Save(@"F:\E\Curren_Running_Projects\WindowApplication\", ImageFormat.Jpeg);
57 | }
58 | }
59 |
60 |
61 | private void button1_Click(object sender, EventArgs e)
62 | {
63 | WebClient Client = new WebClient();
64 | Client.DownloadFile("http://lurieunaward.com/1st_Alfredo_Sabat_cartoon2006.jpg", "F:\\1st_Alfredo_Sabat_cartoon2006.jpg");
65 |
66 | Download();
67 | GetImage();
68 | SaveImage();
69 | //string str = "http://www.wallcoo.net/cartoon/index4.htm";
70 |
71 | //string rs = httpHelper.getHtmlfromUrl(new Uri(str));
72 |
73 | //lst = GetSourceTags(rs);
74 | //lst1 = globusRegex.GetUrlsFromString(rs);
75 |
76 | }
77 |
78 | public List GetSourceTags(string HtmlData)
79 | {
80 | List lstAnchorUrl = new List();
81 |
82 | Regex anchorTextExtractor = new Regex(@"src=[""'](?[^""^']+[.]*)[""'].*>");
83 | foreach (Match url in anchorTextExtractor.Matches(HtmlData))
84 | {
85 | if (url.Value.Contains(".jpg"))
86 | {
87 | lstAnchorUrl.Add(url.Value);
88 | }
89 | }
90 |
91 | //String url = @"
";
92 | //String pattern = @"
[^""]*)""\salt=""(?[^""]*)";
93 | //Regex rx = new Regex(pattern);
94 | //Match m = rx.Match(HtmlData);
95 | //if (m.Success)
96 | //{
97 | // String newUrl = @" lst = new List();
24 | List lst1 = new List();
25 |
26 | public Form1()
27 | {
28 | httpHelper = new GlobusHttpHelper();
29 | globusRegex = new GlobusRegex();
30 | InitializeComponent();
31 | }
32 | private string imageUrl;
33 | private Bitmap bitmap;
34 | public Form1(string imageUrl)
35 | {
36 | this.imageUrl = "http://lurieunaward.com/1st_Alfredo_Sabat_cartoon2006.jpg";
37 | }
38 | public void Download() {
39 | try {
40 | WebClient client = new WebClient();
41 | Stream stream = client.OpenRead("http://lurieunaward.com/1st_Alfredo_Sabat_cartoon2006.jpg");
42 | bitmap = new Bitmap(stream);
43 | stream.Flush();
44 | stream.Close();
45 | }
46 | catch (Exception e) {
47 | Console.WriteLine(e.Message);
48 | }
49 | }
50 | public Bitmap GetImage() {
51 | return bitmap;
52 | }
53 |
54 | public void SaveImage() {
55 | if (bitmap != null) {
56 | bitmap.Save(@"F:\E\Curren_Running_Projects\WindowApplication\", ImageFormat.Jpeg);
57 | }
58 | }
59 |
60 |
61 | private void button1_Click(object sender, EventArgs e)
62 | {
63 | WebClient Client = new WebClient();
64 | Client.DownloadFile("http://lurieunaward.com/1st_Alfredo_Sabat_cartoon2006.jpg", "F:\\1st_Alfredo_Sabat_cartoon2006.jpg");
65 |
66 | Download();
67 | GetImage();
68 | SaveImage();
69 | //string str = "http://www.wallcoo.net/cartoon/index4.htm";
70 |
71 | //string rs = httpHelper.getHtmlfromUrl(new Uri(str));
72 |
73 | //lst = GetSourceTags(rs);
74 | //lst1 = globusRegex.GetUrlsFromString(rs);
75 |
76 | }
77 |
78 | public List GetSourceTags(string HtmlData)
79 | {
80 | List lstAnchorUrl = new List();
81 |
82 | Regex anchorTextExtractor = new Regex(@"src=[""'](?[^""^']+[.]*)[""'].*>");
83 | foreach (Match url in anchorTextExtractor.Matches(HtmlData))
84 | {
85 | if (url.Value.Contains(".jpg"))
86 | {
87 | lstAnchorUrl.Add(url.Value);
88 | }
89 | }
90 |
91 | //String url = @"
";
92 | //String pattern = @"
[^""]*)""\salt=""(?[^""]*)";
93 | //Regex rx = new Regex(pattern);
94 | //Match m = rx.Match(HtmlData);
95 | //if (m.Success)
96 | //{
97 | // String newUrl = @"
2 |
3 |
4 | Debug
5 | AnyCPU
6 | 9.0.30729
7 | 2.0
8 | {FC8B58A9-FB29-4329-9C5C-2303E516B132}
9 | WinExe
10 | Properties
11 | ImageCrawler
12 | ImageCrawler
13 | v3.5
14 | 512
15 |
16 |
17 | true
18 | full
19 | false
20 | bin\Debug\
21 | DEBUG;TRACE
22 | prompt
23 | 4
24 |
25 |
26 | pdbonly
27 | true
28 | bin\Release\
29 | TRACE
30 | prompt
31 | 4
32 |
33 |
34 |
35 | False
36 | ..\..\..\WebApplication\Modified TwtZilla\GlobusLib\bin\Debug\GlobusLib.dll
37 |
38 |
39 |
40 | 3.5
41 |
42 |
43 | 3.5
44 |
45 |
46 | 3.5
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 | Form
57 |
58 |
59 | Form1.cs
60 |
61 |
62 |
63 |
64 | Form1.cs
65 |
66 |
67 | ResXFileCodeGenerator
68 | Resources.Designer.cs
69 | Designer
70 |
71 |
72 | True
73 | Resources.resx
74 |
75 |
76 | SettingsSingleFileGenerator
77 | Settings.Designer.cs
78 |
79 |
80 | True
81 | Settings.settings
82 | True
83 |
84 |
85 |
86 |
93 |
--------------------------------------------------------------------------------
/Facebook Scraper/Properties/Resources.resx:
--------------------------------------------------------------------------------
1 |
2 |
3 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 | text/microsoft-resx
107 |
108 |
109 | 2.0
110 |
111 |
112 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
113 |
114 |
115 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
116 |
117 |
--------------------------------------------------------------------------------
/Facebook Scraper/Form1.resx:
--------------------------------------------------------------------------------
1 |
2 |
3 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 | text/microsoft-resx
110 |
111 |
112 | 2.0
113 |
114 |
115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
116 |
117 |
118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
119 |
120 |
--------------------------------------------------------------------------------